Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Easily Add New Pages


jhilgeman

Recommended Posts

But where in what line in includes/application_top.php

do you add // New page about_us.php

 

define('FILENAME_ABOUT_US', 'about_us.php');

In a sacred manner I live, in heaven I gaze, in a sacred manner I live my horses are many.

Link to comment
Share on other sites

  • Replies 125
  • Created
  • Last Reply

But where or in what line shall I add this in includes/application_top.php

 

// New page about_us.php

 

define('FILENAME_ABOUT_US', 'about_us.php');

In a sacred manner I live, in heaven I gaze, in a sacred manner I live my horses are many.

Link to comment
Share on other sites

  • 1 month later...

Hey Burt!

 

This is a great tutorial, but I'm wondering where I'm putting this last snippet of code in the application_top.php file?

 

Thanks!

 

 

Download, and open up application_top.php and add the following:

// New page about_us.php

define('FILENAME_ABOUT_US', 'about_us.php');

Save and upload includes/application_top.php

Now go Admin > Tools > Define Languages > about_us.php

Done. It sounds complicated but once you get the hang of it, it takes no longer than 2 minutes. It maintains the proper Osc structure.

Link to comment
Share on other sites

Burt's not around anymore, which is too bad. But in answer to your question, that change goes in the includes/filenames.php file. It used to go in application_top but that was changed with a version update.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

i am still kinda lost. I am trying to ass a new page that shows what clothing companies i carry. I use sts, so i changed the template thing into my table setup, and i did that filename_mens.php in it thing. I added a new define in filenames.php, i uploaded application_top, and i uploaded english/mens.php (but i am kinda lost on tht one). For the english/newfilename.php file is that the file you add your info on? If so i did that too... After all that i get this error...

Warning: main(includes/languages/english/Mens.php) [function.main]: failed to open stream: No such file or directory in /home/bleubayc/public_html/osc/mens.php on line 15

 

Warning: main(includes/languages/english/Mens.php) [function.main]: failed to open stream: No such file or directory in /home/bleubayc/public_html/osc/mens.php on line 15

 

Warning: main(includes/languages/english/Mens.php) [function.main]: failed to open stream: No such file or directory in /home/bleubayc/public_html/osc/mens.php on line 15

 

Fatal error: main() [function.require]: Failed opening required 'includes/languages/english/Mens.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/bleubayc/public_html/osc/mens.php on line 15

 

it says that there is no file, but there is... it is weirddddd :-/ this is confusing me ahhh... please help

The "Add New Pages Using STS" contribution located in the STSv4 Power Pack site could really help you out with this. (see STSv4 Power Pack link in my signature below)

Bill Kellum

 

Sounds Good Productions

STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE

Link to comment
Share on other sites

hello everyone

I'm really new in oscommerce and php isn't my favorite language, sorry but i had to say that at the beginning. I'm writing in this topic because I thought it's the most similar to the problem I have. I was wandering how could I add a new "box" in the column_right.php, becouse right now it is showing the products in the store. The idea is that the main page is somekind of invitation page. Then by choosing a product from the column_left it directs customer to the products. And here is another thing I would like to change. In my store there are general product categories ,when You click on them there is a drop down menu where you can choose a product. I would like something like description of this general product categories in the right instead of product listing, so when you click on the general product the page is going to reload and there's going to product listing in the drop down menu on the left and description of the group of products in the right. Could anyone give me any ideas how to solve it, and if it's possible in really easy way. I know other programming languages I just missed php:)

Thank You in advance

 

hgrzesiek

P.S. I hope i wrote it clear for everyone

Link to comment
Share on other sites

  • 3 weeks later...
Your way is good, but better (IMO):

Download the following files:

catalog/conditions.php

catalog/includes/languages/english/conditions.php

Save them (on your Hard Drive as):

catalog/template.php

catalog/includes/languages/english/template.php

When you want a new page:

Open catalog/template.php (on your HD) and change the following:

 

Useing berts example, which is very good for normal pages, i am struggling to include within the text fields on the new page to put my ressellers link into it, the code just does'nt seem to be recgonised?

 

is there a way to include external links without creating a page outside of OSC?

Link to comment
Share on other sites

hello everyone

I'm really new in oscommerce and php isn't my favorite language, sorry but i had to say that at the beginning. I'm writing in this topic because I thought it's the most similar to the problem I have. I was wandering how could I add a new "box" in the column_right.php,

This may help.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Useing berts example, which is very good for normal pages, i am struggling to include within the text fields on the new page to put my ressellers link into it, the code just does'nt seem to be recgonised?

 

is there a way to include external links without creating a page outside of OSC?

What is the code you are using for the link?

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

<a href="java script: void(0);" onClick="var win = window.open('https://www.enta.net/emb/?resellerID=****&reseller=*************************************=1', 'BuyNow', 'top='+((screen.height-600)/2)+',left='+((screen.width-800)/2)+',width=800,height=600,toolbars=no,menubar=no,status=yes,resizable=yes,scroll
bars=yes');return false;">Order Now</a>

 

Thats wot i'm trying to inculde. Theres other code with it, it fails at the url at "//" its sees it as a note(or wotever they are called).

 

Please help!!!!

Link to comment
Share on other sites

  • 2 weeks later...

At the beginning of this thread someone mentioned a add-on for dynamically created pages - does anyone know the name of it? I am looking really for an add-on that will allow pages to be created from the controlpanel.

Link to comment
Share on other sites

  • 3 weeks later...
Check the permissions on the new files. Make sure they are the same as the ones in the same directory.

 

Jack

 

Thanks. One problem solved, another created :lol: -

 

 

Fatal error: Cannot redeclare class tablebox:messagestack in /home/jaide/public_html/includes/classes/message_stack.php on line 20

Link to comment
Share on other sites

That error shouldn't have occurred by just addig a new page unless you used some page that has special coding in it as a reference. Is the error only happening on your new page? If so, then try replacing the new page files with copies of the privacy files and see what happens.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

That error shouldn't have occurred by just addig a new page unless you used some page that has special coding in it as a reference. Is the error only happening on your new page? If so, then try replacing the new page files with copies of the privacy files and see what happens.

 

Jack

 

Yes, only on the new page. I copied the privacy page and replaced the FILENAMEs exactly as stated

Link to comment
Share on other sites

  • 2 months later...

Hi guys i did everything that you guys told me change it to template then rename etc etc

but at moment my link "buyer guide is still not coming up on website even though i have done everything that was told in the post topics please can someone help

Link to comment
Share on other sites

I tried to add simple page testpage.php and now i have problems

 

http://www.wonderjewelers.com/testpage.php

 

What does this mean

 

Warning: main(templates/content/WJ1/.tpl.php) [function.main]: failed to open stream: No such file or directory in /home/.doobie/kusuma1/wonderjewelers.com/templates/WJ1/main_page.tpl.php on line 72

 

I was told my site was highly customized old template and that is why I am having problems

Link to comment
Share on other sites

  • 4 weeks later...

Archived

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

×
×
  • Create New...