Typo In Viewtopic.php


Subject: Typo In Viewtopic.php
viewtopic.php

I was nosing around looking for something - -

$$

Code: [Download] [Hide] [Select]
$topic_user_from_flag = $$forum_topic_data['user_from_flag']


;)

Profile PM  
Subject: Re: Typo In Viewtopic.php
That's not a typo, that's just a dynamicly named variable. Look :

Code: [Download] [Hide]
  1. $a = 50; 
  2. $foo = 'a'; 
  3. echo $$foo; //prints 50 

Profile PM  
Subject: Re: Typo In Viewtopic.php
Thanks,

I learn something everyday from here. :mryellow:

But the last time I did that as a typo - it caused me all sorts of grief. :(

So one just assumed - - -

Profile PM  
Subject: Re: Typo In Viewtopic.php
It can happen in little viewed files but usually something like this produces an error, and in the viewtopic I believe this would've been spotted.

Profile PM  
Subject: Re: Typo In Viewtopic.php
I believe anything about phpBB code that starts in one file, goes through half a dozen more and finally ends up in the tpl file? :(

The reason I was there is because I took the Country Flags mod DB and ported it to my playground and ended up adding the Country automatically to the flag both on the same line and mouse-over and inserting it into the user-profiles wherever the flag is shown and moused over.

Location - Becomes - "Paris, Rome or Oodnawoopwoop etc, and on mouse-over the alt/title is "Rome Italy" - "Paris France" etc.

As in the pic.

flag

Trying to dig where all of that is put together in Icy/phpBB files and do the same thing for IP, is an exercise in itself :(

Maybe you would like to do it, because currently the only information one gets from the flag most of the time is that it's just a "little coloured rectangle" made up from about 24-36px. :LOL:

To make a point - Mouse over my Flag here, and my location is "Behind You" - If it was "Behind You Australia" it would at least make some sense, because for me, like others - the flags that are used here denote nothing because of their size, and mean very little to anyone because there is seldom any Country recognition of the flag itself.

:mrgreen:

Profile PM  
Subject: Re: Typo In Viewtopic.php
Thanks for the suggestion, I'll think about this.

Subject: Re: Typo In Viewtopic.php
My friend if it was easy for me to dig out I would have done it because it's such a bit of easy coding just to echo the "country_name" where the user flag = user id.

;)

Profile PM  

Page 1 of 1


  
You cannot post new topics
You cannot reply to topics
You cannot edit your posts
You cannot delete your posts
You cannot vote in polls
You cannot attach files
You can download files
You cannot post calendar events

   

This is a "Lo-Fi" version of our main content. To view the full version with more information, formatting and images, please click here.

Powered by Icy Phoenix based on phpBB
Generation Time: 0.7846s (PHP: 2% SQL: 98%)
SQL queries: 29 - Debug Off - GZIP Enabled