Welcome to Geeklog, Anonymous Tuesday, December 10 2024 @ 10:48 pm EST

Geeklog Forums

No States in Events

Page navigation


Aerocream

Anonymous
When creating a event there is no states listed in the Dropdown menu. I have two sperate installations of Geeklog, on two differnt servers and both have this issue. I've checked the config.php and the Array is stated and in proper syntax. Also I have checked the event.php file under admin which seems to be correct. Any help would be apperciated. Thanks!
 Quote

Aerocream

Anonymous
Bump for some Attention.
 Quote

Status: Banned

machinari

Forum User
Full Member
Registered: 03/22/04
Posts: 1512
What is your Geeklog version? and your theme?
Even better, give us a URL and we can just look at the page.
 Quote

Aerocrem

Anonymous
www.Aerocream.com, using Geeklog 1.3.11sr3, with the Professional Theme. I've downloaded the newest Full Release of GL and have overwritten the events.php, and totally re-worked my config.php to no avail. Thanks!
 Quote

Status: Banned

machinari

Forum User
Full Member
Registered: 03/22/04
Posts: 1512
just visited your site and I can see the states listed in the dropdown.
maybe refresh your browser cache?
 Quote

Status: offline

Aerocream

Forum User
Newbie
Registered: 12/29/05
Posts: 10
Location:Naples, FL
Cleared both IE and Firefox, tried a different PC, still no states. Now I did have a PHP.INI file that I renamed to see if anything would break and my Forums did.. I renamed it back and that brought my forums to be where they should but still no states. Would there be something in the INI File? Should I Post it ?

Your Help is greatly appreciated!
http://www.aerocream.com
 Quote

mach

Anonymous
PHP version?
 Quote

Status: offline

Aerocream

Forum User
Newbie
Registered: 12/29/05
Posts: 10
Location:Naples, FL
4.4.1, Also I checked the Source of the events.php as seen through the browser, and I have 51 of these for the states

Text Formatted Code
<option value="--" selected="selected">
 

http://www.aerocream.com
 Quote

Status: Banned

machinari

Forum User
Full Member
Registered: 03/22/04
Posts: 1512
ensure that your events.php, in the function editevent(), contains this code, especially the last line, next($_STATES);, :
Text Formatted Code
    for ($i = 1; $i <= count($_STATES); $i++) {
        $state_options .= '<option value="' . key($_STATES) . '" ';
        if (key($_STATES) == $A['state']) {
            $state_options .= 'selected="selected"';
        }
        $state_options .= '>' . current($_STATES) . '</option>';
        next($_STATES);
    }



 

if it does, then either your array is messed up in config.php, or your PHP is having trouble with the next() function.

hmmm.. adding a new event, $A['state'] should be empty in which case the text, selected="selected", should never make it into $state_options. vewy stwange.

You mentioned that you have "reworked" your config.php (what does that mean?) and overwritten your events.php file with the latest version, but did you actually do a proper upgrade to your site or just mix and match files and/or parts of files? Also, post your $_STATES array--at least the first 3 or 4 and the last 2 lines of it.
 Quote

Status: offline

1000ideen

Forum User
Full Member
Registered: 08/04/03
Posts: 1298
When I got to your page and click Submit an Event then I see states. Do you mean you are inside as admin using the left menu?

The most likely thing is that you messed up the config.php could you post the respective part of it?

~~~~
No, just thinking - if it was messed up I couldn`t see them either. The only explanation is that you approach the menu in a different way. Can you try it as anonymous?
 Quote

Status: offline

Aerocream

Forum User
Newbie
Registered: 12/29/05
Posts: 10
Location:Naples, FL
To clarify this is when I try to submit an event as the admin or a user with full admin rights. I see the states when I'm on the site not registered, however when I log in, the states are not visable.

When I said I reworked my config.php, I printed out the current one, deleted it and copied the new blank config from the most current release of geeklog. Also I copied over the events.php from that same release and over written the existing file. The file is http://www.aerocream.com/admin/event.php

Here is a copy of my config.php and the file about events.php

Config.php in TXT
event.php in TXT
http://www.aerocream.com
 Quote

Status: offline

1000ideen

Forum User
Full Member
Registered: 08/04/03
Posts: 1298
Maybe you just copy over that file again and also /admin/event/eventeditor.thtml

I just checked and had absolutely no probs with that also not in various languages.
 Quote

Status: offline

Aerocream

Forum User
Newbie
Registered: 12/29/05
Posts: 10
Location:Naples, FL
Copied over the the the event.php, and the entire event folder under the layout. Overwritten all files on the site. Still the same issue.

Copy of PHP.ini in TXT
http://www.aerocream.com
 Quote

Status: offline

1000ideen

Forum User
Full Member
Registered: 08/04/03
Posts: 1298
If you don`t see the whole dropdown menu ( is there a gap?) it should be in the thtml I suppose.

Last idea: /submit/submitevent.thtml
 Quote

Status: offline

Aerocream

Forum User
Newbie
Registered: 12/29/05
Posts: 10
Location:Naples, FL
Uploaded the whole submit folder.. Still no change Sad
http://www.aerocream.com
 Quote

Status: offline

Aerocream

Forum User
Newbie
Registered: 12/29/05
Posts: 10
Location:Naples, FL
I really Appreciate all the help both you two have given. I don't want to waste anyone else's time on this issue, so what I've done is taken out the For Statement and just set the Variable to the following below..

Text Formatted Code
$state_options = '<select name="state"><option value="--"></option><option value="AL">Alabama</option.....<option value="WY">Wyoming</option></select>'
 


The states aren't going to change anytime soon, and this just patches this issue for the time being. Happy New Year Everyone! Its a deal - shaking hands
http://www.aerocream.com
 Quote

Status: offline

1000ideen

Forum User
Full Member
Registered: 08/04/03
Posts: 1298
Well, maybe with the update to 1.4.0 in a few days the problem will have solved. Happy New Year!
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
I seem to remember that a certain PHP version had problems with the current / next functions.

In 1.3.11, submit.php uses a foreach loop for the states, while admin/event.php uses current/next. In 1.4.0, they both use foreach ...

Not sure if that really explains anything, though. Geeklog uses current/next in quite a few places, so you should see similar problems elsewhere, too, if it were really related to your PHP version Neutral

bye, Dirk
 Quote

Phil

Anonymous
confused
I too have the same issue.
PHP Version = 4.4.1
GL version = 1.3.11sr1


The events submission works fine as a guest user, however, login as a user and you see the first listed state repeated.

Tried submitting an event as a guest, all OK, logged in and approved the event and it saved OK. Go to edit the event and the state issue still there.

Is this a security issue that is upsetting this part of the code?

View site

I may need to commit and upgrade GL!!!!

BTW: Great product, keep up the great work.

Phillip
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Quote by Phil: Is this a security issue that is upsetting this part of the code?

No, it's not a security issue, it's a bug in PHP itself.

If this is the bug I mentioned above, then you may want to upgrade to PHP 4.4.2 when it comes out "at the end of next week".

bye, Dirk
 Quote

Page navigation

All times are EST. The time is now 10:48 pm.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content