Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Archived

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

RAC

website page not working following installing Edit Pages

Recommended Posts

Hi all

 

I have just installed Edit Pages, http://addons.oscommerce.com/info/9191  on my 2.3.4. site.

Now the Shipping page on my site is not working and I get the following message :

 

 

“The retro-antiques-curios.co.uk page isn’t working

 

retro-antiques-curios.co.uk is currently unable to handle this request.

 

HTTP ERROR 500

 

Reload”

 

Any ideas?

Share this post


Link to post
Share on other sites

Hello Shaun @@RAC,

 

If you are using a SEO URL add-on, check that the correct rewrite rules for these pages are included in your .htaccess

 

rgds

Rainer

Share this post


Link to post
Share on other sites

Hello Rainer

 

Thanks for the reply, sorry to be a pain, as stated before I am new to OSC and have never done any HTML or PHP before.

 

I have no other add-ons installed except for Royal Mail Shipping Modules and the CK Editor, (4.6.2_basic), not including the kc finder.

The only other mods I have done is to change to the UK date format, and remove all countries except UK for payment and shipping.

 

I installed the Unmodified site, without CK Editor (FULL) version, was this correct? 

 

Further, all of the other Information pages on my website I get the following error:

 

1146 - Table 'retroant_osco478.linuxuk_edit_page_privacy' doesn't exist

select * from linuxuk_edit_page_privacy where linuxuk_edit_privacy_language_id = 1

[TEP STOP]

 

Have I missed uploading a table to the database?

 

Regards Shaun

Share this post


Link to post
Share on other sites

I have just checked in MyAdmin, at the top of the page, the MySQL database name is different, to the DB name in Cpanel, could this be the problem?

Share this post


Link to post
Share on other sites

Lots of things can cause a 500 error. In your case (installing an add-on), I would first look at the following:

  • Invalid php.ini or .htaccess entries that you copied over without checking that your system accepts them. This could include phpvalue, phpflag, and Options commands (on some servers).
  • Mistakes in editing that left a blank or empty line before the first <?php or after the last ?>.
  • Bad file or directory permissions, such as "world writable" 666 or 777 permissions banned by many hosts.

If none of those are the problem, look at http://www.catskilltech.com/freeSW/SMF/faqs/index.html#err500 for a list of other causes.
 
It sounds like you did miss uploading a table (or creating it) on the database. It's looking for a table named linuxuk_edit_page_privacy that includes fields such as linuxuk_edit_privacy_language_id. It's possible the installer failed while trying to do this, due to configuration problems.
 
In some places, your database name (as well as user name) may have your hosting account name prefixed to it, while in other places you may not see that. It depends on just how your server and database are set up. Consult with your hosting service to understand how such names should be used.

Share this post


Link to post
Share on other sites

Hello MrPhil

 

Thanks for the info.

 

I have sorted out the "table" problem, I neglected to upload into phpMyAdmin, d'oh!

 

I have tried to sort out the "page not working" problem, so far without success, there does not seem to be any extra spaces at the beginning or the end characters.

I will carry on through the link you supplied, however it is only the shipping page that is affected, and only since installing Edit Pages, the other information pages seem to be working fine. 

 

I will post when I find the problem.

Share this post


Link to post
Share on other sites

I hate having to ask questions, and do try to sort problems out myself.  I have spent hours looking through the information suggested, I am at a total loss.

 

I can not find any php.ini files, I have only copied and pasted the code for edit pages, (no editing) I do not remember any such file to replace.

 

Was I supposed to upload the htaccess file included with the edit pages instructions? it does not look the problem :

AuthType Basic AuthName "No access" AuthUserFile .htnopasswd AuthGroupFile /dev/null Require valid-user

 

The only item that jumps out to me in the link supplied is that I used Filezilla,  how can I tell what mode the files were uploaded with?

 

But as I stated before, it is only the shipping page I have the problem with, would one of these errors cause the same problem with my other info pages that I changed at the same time?

 

Shaun

Share this post


Link to post
Share on other sites

Most hosting accounts do not come with a pre-made php.ini file. You have to create it yourself. Ask your host for any particulars such as special naming instructions, where to place it, etc. You may need to add a line to .htaccess telling PHP where to find php.ini.

 

By the way, at a minimum, php.ini should set your time zone:

date.timezone = 'America/Los_Angeles'

or whatever time zone you're in. Possibly your host has already done something along these lines. Ask them.

 

You generally don't want to overwrite your existing .htaccess file with the one supplied by osC. You want to understand what the supplied commands are for, whether they are appropriate for your situation, and then merge them into any existing .htaccess. By the way, it's not good to install any application (such as osC) into the root directory -- it should be in its own subdirectory, such as /catalog or /shop. And .htaccess only applies to Apache servers anyway -- other kinds of servers (Windows, nginx, etc.) use something different.

 

The "AuthType" command is to add password protection to your store's admin directory. What is supplied with osC often will not work without some tweaking. You may be better off using your hosting control panel to set password protection on 'admin' (or whatever you rename it to). osC security monitoring pages may then complain that you have no password protection implemented, but if you're asked for a password on admin, it's working and you can ignore those messages.

 

FileZilla is generally pretty good about uploading in the right mode, unless you do something tricky that confuses it. If you're concerned, look at an example of each file type (extension) you uploaded. .php, .js, .css files should be human readable (the lines are separate and not run together, without extra blank lines). .gif, .jpg, .png files should display properly in a browser or picture editor. There might be a few other file types floating around.

 

You say your shipping page is not working. Is it still getting a database error, or are you getting an error that there's a problem in the file?

Share this post


Link to post
Share on other sites

Hello again MrPhil

 

I run 10 small websites off of a WHUK Reseller linux Apache hosting account, each of the websites have been created on rvsitebuilder, or similar, WYSIWYG platform, so I have not needed to edit any code before now, (this is a steep learning curve!).

 

The Oscommerce site is bundled with the account as a one click install, and is located in home/public_htm/storename .

 

Initially I was editing my Osc through WHM 60.0, Cpanel, File Manager, as I was unaware of FTP, until reading many posts on the forum, which have all stated that FM is not the way to edit files.

 

My host does not let me access php.ini -

 

“If you have a shared hosting package or reseller hosting package with us, we don’t allow to access the php.ini on server. But as per client requirement they can use the .htaccess file from his hosting package to enable or disable various php.ini functions.”

 

So can I use .htaccess to sort this problem out?

 

I found a previous communication from several months ago, on an earlier store, but I restarted from fresh with this store. This maybe miles off of the mark, however would this help? –

 

Additional Protection With htaccess/htpasswd

This osCommerce Online Merchant Administration Tool installation is not additionally secured through htaccess/htpasswd means.

Enabling the htaccess/htpasswd security layer will automatically store administrator username and passwords in a htpasswd file when updating administrator password records.

Please note, if this additional security layer is enabled and you can no longer access the Administration Tool, please make the following changes and consult your hosting provider to enable htaccess/htpasswd protection:

1. Edit this file:

/home/public_html/****/admin/.htaccess

Remove the following lines if they exist:

##### OSCOMMERCE ADMIN PROTECTION - BEGIN #####
AuthType Basic
AuthName "osCommerce Online Merchant Administration Tool"
AuthUserFile /home/retroantiquescur/public_html/oscom/admin/.htpasswd_oscommerce
Require valid-user
##### OSCOMMERCE ADMIN PROTECTION - END #####

2. Delete this file:

/home/public_html/****/admin/.htpasswd_oscommerce

 

 

The error message I am currently getting is :

 

“The ***co.uk page isn’t working

 

****.co.uk is currently unable to handle this request.

 

HTTP ERROR 500

 

Reload”

 

 

The database problem has been sorted, I missed a table to upload, these pages are running fine now.

Share this post


Link to post
Share on other sites

I would be wary of any host who does not let you create some sort of php.ini file (or equivalent). If you need to use phpvalue and phpflag entries in .htaccess to do the job, it means their software is very backlevel!

 

Speaking of backlevel code, if you're using a "one click" installer for osC, they are at best offering version 2.3.4, which is getting fairly obsolete. It doesn't even run on current PHP levels (like 5.6). If you're just starting out, you'll be much better off in the long run installing osC 2.3.4BS Edge (from Github). At least try installing and configuring it. If it still defeats you, you're simply at the mercy of your host and will have to use whatever they supply to you.

 

A hosting control panel's File Manager is usually a fairly clumsy way to edit files, but it's legitimate. For very small changes, it's easier than FTPing a file down to your PC, editing it (with a real editor such as ViM or Notepad++, never with Word or another word processor!), and FTPing the file back up. By the way, you should have a complete copy of your site on your PC, as a backup if nothing else, so you can edit there and upload (avoiding the FTP download step).

 

Regarding the "Additional Protection" stuff, if you don't know what you're doing, avoid using the osC-supplied changes to .htaccess (and related) to implement password protection on your admin directory. You will almost always have to make some manual tweaks to what osC supplies. Use your hosting control panel's "Password protect a directory" function instead. If they don't offer that, run away from them as fast as you can, and get a real host. osC may complain from time to time that you don't have password protection enabled, but if you are required to enter a separate ID and password to access admin functions, it's working and you can ignore that message.

Share this post


Link to post
Share on other sites

Thanks MrPhil, I thought the 2.3.4.BS was under development still, and as such suitable for experienced users only.

Do you think that I could develop a BS store with my limited knowledge?

If so I would be willing to have a go.

Share this post


Link to post
Share on other sites

Well, technically it is still under development. However, it is ready to use out of the box, and many people are successfully using it for production stores. The only downside is that your "one button" installer won't do the job, and you will have to do a manual install (which involves very little coding or editing, unless you want to get fancy). Read the instructions and see if you're up to it -- it's not hard at all, just requiring attention to detail. Make a test installation somewhere and play with it -- you can't break anything, but you will require a little more knowledge than pressing one button.

 

Note that some updates for the official product line (currently 2.3.4) have been promised: 2.3.5 bug fix for 2.3.4 (and maybe PHP 5.6 or 7 compatibility, but not responsive) and 2.4 (PHP 7, responsive). Unfortunately, given the past history of osC releases, I would definitely not wait for either of them. They could come out next week, or it could literally be years before you see either of them as the standard release. I'm betting on the latter. It's totally beyond me why Harald et al. have not learned any lessons from osC's long term continuing loss of market share due to such infrequent product refreshes. 2.3.4BS should have been officially released as either 2.3.5 or 2.4, but wasn't and won't be. NIH factor, I guess. When 2.4 eventually comes out, it should be an easy upgrade from 2.3.4BS.

 

Once you get to the stage of developing (customizing) your store (either installing add-ons or custom coding), there's no real difference between 2.3.4 and 2.3.4BS. Either one will require the same level of expertise, which you will have to grow into.

Share this post


Link to post
Share on other sites

×