Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Poll Causing Error on Coppermine  (Read 4013 times)

0 Members and 1 Guest are viewing this topic.

element059

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Poll Causing Error on Coppermine
« on: October 09, 2004, 03:06:50 am »

Hello,

When users click vote or results on my poll it creates an error with Coppermine. See here:

http://www.games-fusion.net/screens/themes/classic/template.php?vo=6

The page should be:

http://www.games-fusion.net/screens/index.php?cat=15

I don't understand why it is doing this as it works on all my other pages.

Many thanks!
Logged

kegobeer

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 4637
  • Beer - it does a body good!
    • The Kazebeer Family Website
Re: Poll Causing Error on Coppermine
« Reply #1 on: October 09, 2004, 03:55:48 am »

Have you looked at dovote.php to see what it's doing after a vote is cast?
Logged
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

element059

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: Poll Causing Error on Coppermine
« Reply #2 on: October 09, 2004, 04:18:53 am »

No but then again I don't know what dovote.php is ;)?
Logged

kegobeer

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 4637
  • Beer - it does a body good!
    • The Kazebeer Family Website
Re: Poll Causing Error on Coppermine
« Reply #3 on: October 09, 2004, 04:39:59 am »

Uhhh, ok.

dovote.php is a file that takes care of your voting system, at least that's what I gather from viewing your page's source code.  I don't know how it works - that's up to you to figure out, since it's on your website and all.
Logged
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

element059

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: Poll Causing Error on Coppermine
« Reply #4 on: October 09, 2004, 11:47:22 am »

Hello,

I thought you might kno since it doesnt do it on any of my other scripts I thought it might be a compatibility issue with coppermine!?
Logged

kegobeer

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 4637
  • Beer - it does a body good!
    • The Kazebeer Family Website
Re: Poll Causing Error on Coppermine
« Reply #5 on: October 09, 2004, 01:36:35 pm »

Again, since I don't know what that file is or exactly what it does, I can't diagnose or fix the problem.  You have to look at the file and compare it with the files in Coppermine to see what's causing this problem.
Logged
Do not send me a private message unless I ask for one.  Make your post public so everyone can benefit.

There are no stupid questions
But there are a LOT of inquisitive idiots

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Poll Causing Error on Coppermine
« Reply #6 on: October 09, 2004, 03:35:36 pm »

to clarify this: dovote.php is not a file that comes with coppermine, it has either been created by you or came with another application you have on your webserver. Since it's not a coppermine core file we (the coppermine dev team members) can't tell what it does or why it doesn't do what it is exoected to do.
If you think dovote.php actually is a coppermine file, then please let us know where you got coppermine from - it must then be a third party side...

Joachim
Logged

element059

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: Poll Causing Error on Coppermine
« Reply #7 on: October 09, 2004, 07:43:51 pm »

Hello,

dovote.php is a voting system which I have been using for years, it has nothing to do with coppermine just to be clear :).

Here's what is in the code:

Code: [Select]
<?php

// detect file extension
$dotloc strrpos(__FILE__".");
$ext substr(__FILE__$dotloc+1, (strlen(__FILE__) - $dotloc));

include 
dirname(__FILE__)."/common.${ext}";
include 
dirname(__FILE__)."/classes/poll.${ext}";

$p = new Poll($pid);

$cookiename "symp".$p->tstamp;
if(isset(
$sympvotes[$cookiename])) {
  
$scookie1 $sympvotes[$cookiename]; 
} elseif(isset($
$cookiename)) {
  
$scookie1 = $$cookiename;
}

# tried to vote without selecting an option or option can't 
# be verified as valid or already voted.  attempt to just
# return them to the previous page.
if( (!empty($s_cookielog) && isset($scookie1)) ||
    !isset(
$cid) || !isset($p->options[$cid])) {
  
header("Location: $ref"); 
  exit();
}

if(!empty(
$s_cookielog)) {
  
$date time()+($s_blength 86400);
  
$sympvotes[$cookiename] = $cid;
  
setcookie("sympvotes"serialize($sympvotes), $date"/");
  
$p->inc_vote($cid); 
  
# do_redir for iis cookie+redir bug
  
do_redir("$ref"."$vostr");
} else {
  
$p->inc_vote($cid);
  
header("Location: $ref"."$vostr"); 
  exit();
}

?>

I am not a php programmer :) So if you can see what might be causing the problem please point it out!

Thank you!
Logged

element059

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: Poll Causing Error on Coppermine
« Reply #8 on: October 10, 2004, 11:56:28 pm »

!Bump

Can anyone help me with this!?

Thank you!
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Poll Causing Error on Coppermine
« Reply #9 on: October 11, 2004, 05:34:19 am »

I guess you won't get support for third-party code on this board. I alread posted a link to the faq that explains the possible reasons why people don't answer: they either don't know an answer, or they don't want to look into it because of something you did. In your case, I guess it's for both reasons.

Joachim
Logged
Pages: [1]   Go Up
 

Page created in 0.098 seconds with 15 queries.