Jump to content

Link to static page fails


Will Shaman

Recommended Posts

I'm new to Cubecart, so please forgive me if this basic question is stupidly simple, but I haven't found an answer anywhere. I've just started building a shop in CC6 at http://www.theolyn.com/cube/ and I want to make a simple link to a simple custom (static) page. Pages are apparently called "documents" in Cubecart, so I went to Admin > File Manager > Documents and hit the Create Document tab. There I made a document called Test static page, checked the Status box and gave it the URL http://www.theolyn.com/cube/test . I then see it listed with all the other documents like "Terms and Conditions" and "Privacy Policy", so I know it exists. Then, on the site's home page at http://theolyn.com/cube/ I edited the content to include a link with the URL of my new page. So there's a page with an URL and another page with a link to that URL (which is displayed when I roll over it). This should work, right? Apparently not.

When I click on the link referencing http://www.theolyn.com/cube/test I get a "404 Page not found" error, even though both the page and the link to the page have exactly the same URL. (I tried it both with and without a "/" at the end and it seems to make no difference).

This seems like such a simple, basic piece of page building I can't for the life of me see where I'm going wrong. What am I missing? I'm hugely grateful for anyone who can point me in the right direction. There doesn't seem to be anything on the 'net about this and I've been searching for ages!

Thanks in advance.

Will

Link to comment
Share on other sites

If CubeCart were to make the "search-engine-friendly" URLs, there would be .html at the end and the name would more reflect the document name, such as:
www.example.com/cube/privacy-policy.html

But there isn't and the URL is simply privacy, so I wish to ask if you entered a specific URL on the General tab in the admin Edit Document screen?

If so, there must be an actual separate file for the web server to find.

In regards to test, the URL should not have a trailing slash as, otherwise, that properly indicates that the web server should look in the /test/ folder for a default document file (usually index.php).

Is there a file named test in the /cube/ folder?

Link to comment
Share on other sites

Thanks for the swift response, Bsmither. I appreciate that.

When I created the document I initially gave it the URL test, hoping it would become a relative URL, although when I first encountered the problem of my link not working I noticed CubeCart had changed it to its full URL, ie http://www.theolyn.com/cube/test. Putting to one side my stupid ignorance of the significance of the trailing slash (doh!) I couldn't work out why a link to http://www.theolyn.com/cube/test wouldn't open a document with the URL http://www.theolyn.com/cube/test, hence my post on this forum. But I think you're saying that in order for it to work I need to create a regular HTML page called test.html? My error being the assumption that creating a document within the CubeCart database with the URL test was not something the system could reference? I'm coming from previous experience with Drupal and WordPress, both of which can work like that — I hope this lame amateur is explaining things clearly?

Thanks for your help.

All the best,

Will

Link to comment
Share on other sites

"I think you're saying that in order for it to work I need to create a regular HTML page called test.html?"

If you have "test" as the URL, then it will be relative to www.example.com/cube/, but will not be found as test.html. The document's name must match exactly as you have specified, test. But, yes, specifying a URL for a document requires that you manually create a document file. It could be anything, but it helps to give it a suffix: .html, .pdf, .xls, whatever, so that the web server can inform the browser of the file's mime-type.

This is different with what you may be familiar in regards to Wordpress's 'permalinks'. You may find there will be difficulties getting permalinks to work alongside Cubecart's seo-links. Search the forum for permalinks.

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...