If you are not registered or logged in, you may still use these forums but with limited features. Show recent topics
  [Search] Search   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [FAQ]  FAQ 
[Register] Register / 
[Login] Login 
Poll using wrong url; vote/view results giving 404 error  XML
Forum Index » Support Forum
Author Message
Anonymous



I've been playing with this code ALL day, and have managed to figure most of my issues out so far by searching these forums. However, I am currently baffled by this issue:

The base url for the Vote button and the View Results links are not pointing to the correct directory, so I get a 404 Page Not Found when I click them.

I'm using Version 2.03 (at least I assume it's 2.03 - I downloaded it this morning), textfile based. I've changed the General Settings to show that my poll code is installed in http://starwarschicks.com/polls/ I have configured a custom template, but have set it back to the "default" template (unaltered) and am still having the issue with the wrong URLs.

The poll is displayed on this page (work in progress!): http://www.starwarschicks.com/redesign/newindex.shtml

If someone could help me out, I'd be much appreciative!
amber222
Graduate

Joined: 07/05/2004 21:13:07
Messages: 586
Offline

Your poll files are in a directory called "poll", not "polls".

In admin general settings, remove the "s":

Modify the general settings
  • URL to poll directory: /poll
    URL to image directory: /poll/image
  • Anonymous



    My first thought was, "You're kidding - am I really that stupid?" But I looked, and I do have my General Settings set right. I just added the 's' in the above post by mistake.

    Thanks, but unfortunately it wasn't the correct answer - thought I kind of wish it was.

    Any other ideas?
    Anonymous



    What's this? - taken from your source code:



    The above is pointing to a directory named "polls" which doesn't exist.

    You also have a php include for the poll:



    Suggest you do a search of your newindex.shtml file and make sure you change all instances of directory "polls" to "poll"
    Anonymous



    Thanks, Guest.

    The first problem is completely unrelated. That was linking to an old set of polls used long ago and has nothing to do with the new Advanced Poll. Many of the links in the menubar are wrong - I'm concerning myself with the design first, poll second, and will pull the entire site together later.

    The second point is correct. I am using an SHTML include, which is including the file http://www.starwarschicks.com/poll/poll_current.php

    I guess I need to be a little more specific about my problem. Sorry!

    When you load the above file directly, the poll functions properly. But when it is included, the "View Results" link, for example directs you to http://www.starwarschicks.com/redesign/poll_current.php?action=results&poll_ident=4
    rather than http://www.starwarschicks.com/poll/poll_current.php?action=results&poll_ident=4

    So specifically, my question is: What part of the program script do I have to change in order to get my URL to use the "poll" directory, rather than the "redesign" directory (which is the current directory)? I've not been able to find it. Please don't tell me "Just don't use SHTML includes". That's the easy answer, and I'm sure someone here is intelligent enough to figure out a better answer.

    Thanks!
    Anonymous



    Nevermind! I just figured it out. I knew there was an easy solution...

    I just needed to add "../poll/" before "$this->form_forward" and "$this->form_forward?action=results&poll_ident=$poll_id" in the template.
     
    Forum Index » Support Forum
    Go to:   
    Based on the open source JForum