Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Loading External Text


IMpure

Recommended Posts

As clear from title, I want to display text for TEXT_MAIN from some external Text/Html file. I also want to load external text file for my about us page.

 

Any idea>?

To be or not to be, that is the question!

Link to comment
Share on other sites

I too have the same question. I am helping a friend with her website. Having never used oscommerce before this is all very new. Friends web designer has put site up and is now departed from web design. I have complete access and need to be able to change text and pictures on main page. I had downloaded her page and was able to make corrections using FrontPage. Would rather make changes of Text_Main using FrontPage since oscommerce seems mind boggling on the first day of looking at it.

I haven't even been able to find where Text_Main shows up in the directory.

Any help would be appreciated.

Thank you.

Paula

Link to comment
Share on other sites

Thanks for writing Mark. I think the contribution which you suggested isn't what I am looking for. What I want is to point a path of some external text/html file where I want to display the text. The reason i need this functionality is that I want to give someone with less editing knowledge the ability to change the text for himself.

Do you have any idea for this??

To be or not to be, that is the question!

Link to comment
Share on other sites

I too have the same question. I am helping a friend with her website. Having never used oscommerce before this is all very new. Friends web designer has put site up and is now departed from web design. I have complete access and need to be able to change text and pictures on main page. I had downloaded her page and was able to make corrections using FrontPage. Would rather make changes of Text_Main using FrontPage since oscommerce seems mind boggling on the first day of looking at it.

I haven't even been able to find where Text_Main shows up in the directory.

Any help would be appreciated.

Thank you.

Paula

 

Well, I don't think that you can edit OSC in frontpage because front page is WYSIWYG editor. However, you can edit OSC code using built in HTML editor provided in frontpage. If you want to know where is the link for 'TEXT_MAIN', I can tell you. I am sure this thing have been answered already in the forums.

To be or not to be, that is the question!

Link to comment
Share on other sites

Thank you. I would appreciate it. Yesterday was the first time I had looked at osc and reading text on install to see what previous web person had done. His upload was different than instructions as far as having a file called catalog. I could not find a cache file either. It must be there. I just haven't been able to locate it.

Any help would be much, much appreciated. Things like adding index page (Text_Main) to the files that can be modified (like the about us, contact us, etc) under the control panel would be a big help.

Paula

Link to comment
Share on other sites

Thank you. I would appreciate it. Yesterday was the first time I had looked at osc and reading text on install to see what previous web person had done. His upload was different than instructions as far as having a file called catalog. I could not find a cache file either. It must be there. I just haven't been able to locate it.

Any help would be much, much appreciated. Things like adding index page (Text_Main) to the files that can be modified (like the about us, contact us, etc) under the control panel would be a big help.

Paula

 

 

I'm currently using Cute_News to power certain non-oscommerce specific pages on my store... like

 

http://musica360.com/store/aboutus.php

http://musica360.com/store/musica_magazine.php

 

and even the "privacy policy" and "terms and conditions" pages.

 

There's a simple backend that you can use to edit both regular text and html and you don't have to give anyone access to your oscommerce backend AND can also set up different usernames with different levels of access. This can also be used to create blogs as well.

 

you can download it from here:

http://cutephp.com/

 

I'm currently working on intergrating Joolma into Oscommerce as it offers a ton of features that I need.

My Contribution

Music Download Store Template

http://www.oscommerce.com/community/contributions,4275

Link to comment
Share on other sites

There might be a problem with doing this ....but in theory you could replace

 

<?php echo TEXT_MAIN; ?>

 

with

 

<?php include('http://thesite.com/yourfile.html');?>

 

Would that work? :huh:

 

 

Thanks for writing Mark. I think the contribution which you suggested isn't what I am looking for. What I want is to point a path of some external text/html file where I want to display the text. The reason i need this functionality is that I want to give someone with less editing knowledge the ability to change the text for himself.

Do you have any idea for this??

Link to comment
Share on other sites

There might be a problem with doing this ....but in theory you could replace

 

<?php echo TEXT_MAIN; ?>

 

with

 

<?php include('http://thesite.com/yourfile.html');?>

 

Would that work? huh.gif

 

Very logical....I think this should work. Let me try it. I'll let you know if it worked or not. Thanks anyway

To be or not to be, that is the question!

Link to comment
Share on other sites

Thank you. I would appreciate it. Yesterday was the first time I had looked at osc and reading text on install to see what previous web person had done. His upload was different than instructions as far as having a file called catalog. I could not find a cache file either. It must be there. I just haven't been able to locate it.

Any help would be much, much appreciated. Things like adding index page (Text_Main) to the files that can be modified (like the about us, contact us, etc) under the control panel would be a big help.

Paula

 

I would suggest you to install the latest OSC which is 2.2 I think. You can backup your previous database and then restore it to your newly installed OSC. This will give you more clear vision of where and what are you doing. You can find TEXT_MAIN in /catalog/includes/languages/english/index.php as:-

 

define('TEXT_MAIN', 'THE TEXT WHICH YOU WANT TO DISPLAY');

 

Take care of the syntax.

 

You can create new pages for yourself. Have a look:-

 

http://www.oscommerce.info/kb/osCommerce/C...g_Area/Boxes/49

 

I think you have to edited Contact Us, About Us for yourself. There isn't any option to edit them from some control panel. However, you may review the posts by choosealogin & Mediajuggle. Both sounds right but i haven't yet tried them.

 

Best of luck

To be or not to be, that is the question!

Link to comment
Share on other sites

One more thing Paula. ALWAYS BACKUP! all the files which you are going to edit. Must Back them up! I'm sure you'd be aware of it already but i think I should mention it.

To be or not to be, that is the question!

Link to comment
Share on other sites

Thanks to all of you I found the file I needed. I downloaded and opened with NotePad. Made change. Saved it. Opened my SmartFTP, renamed index.php to xindex.php and uploaded my saved index.php. Worked like a charm. Now I have another question which probably sounds really stupid. I did view the Cute site mentioned above. Wasn't sure if it was what I really needed. Question is: what program is best to use when working with php? NotePad seems to stretch on for miles to the side. Is there a program to use to make viewing and editing easier?

Paula

P.S. My hat is off to all of you who work with php. I have to say it's a new ball game!

Link to comment
Share on other sites

Thanks to all of you I found the file I needed. I downloaded and opened with NotePad. Made change. Saved it. Opened my SmartFTP, renamed index.php to xindex.php and uploaded my saved index.php. Worked like a charm. Now I have another question which probably sounds really stupid. I did view the Cute site mentioned above. Wasn't sure if it was what I really needed. Question is: what program is best to use when working with php? NotePad seems to stretch on for miles to the side. Is there a program to use to make viewing and editing easier?

Paula

P.S. My hat is off to all of you who work with php. I have to say it's a new ball game!

 

Review the following link:-

 

http://www.jedit.org/index.php?page=download

 

Or If you have dreamweaver then you can use it.

To be or not to be, that is the question!

Link to comment
Share on other sites

if (SHOW_TEXT_MAIN == 'true'){

$template->assign_block_vars('index.default.text_main',

array('TEXT_MAIN' => TEXT_MAIN));

}

The above is what I see when I open index.php using NotePad regarding Text_Main.

 

To use the above posted formula of replacing <?php echo TEXT_MAIN; ?>

with

<?php include('http://thesite.com/yourfile.html');?>

in order to pull in a html file, which works according to the above posts, I must be opening the wrong php file. Please tell me which file I am to find the above working code or does the code not show up because TEXT_MAIN is set to true?

I think I will start signing my posts "Really confused".

Thank you and again, any help is really, really appreciated.

Paula "Really confused"

Link to comment
Share on other sites

That sounds like a template...It makes things different.

 

Since I'm not familiar with it...I'll hope that someone else is :huh:

 

if (SHOW_TEXT_MAIN == 'true'){

$template->assign_block_vars('index.default.text_main',

array('TEXT_MAIN' => TEXT_MAIN));

}

The above is what I see when I open index.php using NotePad regarding Text_Main.

 

To use the above posted formula of replacing <?php echo TEXT_MAIN; ?>

with

<?php include('http://thesite.com/yourfile.html');?>

in order to pull in a html file, which works according to the above posts, I must be opening the wrong php file. Please tell me which file I am to find the above working code or does the code not show up because TEXT_MAIN is set to true?

I think I will start signing my posts "Really confused".

Thank you and again, any help is really, really appreciated.

Paula "Really confused"

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...