Jump to content

Tboy_forum

Members
  • Posts

    11
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

Tboy_forum's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Hmmmm.. Just tested with phpDesigner and it does work - will have to go and look why it isn't executing in my file Thanks for that
  2. Thanks But still getting the following result (***** added for obvious reasons): :( Signature done -> [img:160:120:ef49b298be]http://i6.photobucket.com/albums/*****/Mystic_Mark/Photo-0119.jpg[/img:ef49b298be]
  3. Hi all I have the following in a sql database which I need fixing (added www.**** for obvious resons : [img:::119f8aa6a7]http://www.******.com/talk/phpBB2/userpix/2123_scorp2_2.jpg[/img:119f8aa6a7] [img:::119f8aa6a7]http://www.******.com/talk/phpBB2/userpix/2123_pipedream2_1.jpg[/img:119f8aa6a7] [img:::50ef365145]http://img.photobucket.com/albums/******/Franschoek%20270108/vulturebike.jpg[/img:50ef365145] [img:::50ef365145]http://img.photobucket.com/albums/******/Franschoek%20270108/svmarinda.jpg[/img:50ef365145] [img:::50ef365145]http://img.photobucket.com/albums/******/Franschoek%20270108/silversv.jpg[/img:50ef365145] [img:::50ef365145]http://img.photobucket.com/albums/******/Franschoek%20270108/scorpbike.jpg[/img:50ef365145] [img:::50ef365145]http://img.photobucket.com/albums/******/Franschoek%20270108/pdbike.jpg[/img:50ef365145] [img:::b38af58107]http://www.******.com/talk/phpBB2/userpix/2123_DSCF4356_1.jpg[/img:b38af58107] [img:::b38af58107]http://www.******.com/talk/phpBB2/userpix/2123_DSCF4320_1.jpg[/img:b38af58107] Is this code correct for finding the above???: Its not doing anything and the mixed pattern is confusing I am trying to strip the eg: '[img:::b38af58107]' (without quotes) to a normal image code [img] $text = preg_replace('#\[img:([a-z0-9]http://+)\](.*)\[/img:\\1\]#siU', '[img=$2]', $text); Many thanks
  4. You sir, are a genius ;D ;D ;D ;D I must have been dreaming!! I look at the problem and don't even see it - thanks a STACK for spotting that one - I thought I was going nuts Many thanks for all the assistance here, I really do appreciate it
  5. The origin info is either: 1061962 - 5 digits outputs 1-06-1962 if checking for 5 digits is first 12251965 - 6 digits outputs 1-12-8197 and 6 digits is second What I have found is that whatever test condition is first, that is then the resulting output. I.O.W. the second condition is not being executed??? Either the one condition is correct on the output - never both
  6. Thanks for the assistance I am getting the following results 5 digit dates are returning: 10-61-962 instead of 01-06-1962. So it would seem the condition for 5 digits is not being met??? And 6 digit dates are returning: 11-28-1978 - which is correct. Its only the 5 digit dates which are giving me nightmares
  7. Okay - now its dying ;D Obviously, the $bday string is not receiving a valid value to test against. Damn, wish I had a debugger for my 'localhost' Any other ideas??
  8. The input data are dates stored as follows: either 1061962 or 11281978 Data stored in a MySql database. As can be seen, the length of the info is either 5 characters or 6
  9. Tried swopping strlen and trim - still no go :'(
  10. Already tried that without success Not sure if the problem lies here != 6 - its reading an integer field
  11. Hi all Yep, I'm a noob so go lightly please ;D Can someone please assist me with finding the conditional problem here. Its part functioning ??? I.O.W. - I'm not sure where the conditional problem lies. It executes the first part of the code. That is, it does assign values to $year, $month and $day but the condition is wrong - it executes whether the string length is 6 or 5 characters :'( ANY help is appreciated if (trim(strlen($user['user_birthday'])) != 6 ) { $year = substr($user['user_birthday'], 4, 4); $month = substr($user['user_birthday'], 0, 2); $day = substr($user['user_birthday'], 2, 2); } else if (trim(strlen($user['user_birthday'])) != 5 ) { if ($user['user_birthday'] AND $user['user_birthday'] != 999999) { if (trim(strlen($user['user_birthday'])) != 6 ) { $year = substr($user['user_birthday'], 4, 4); $month = substr($user['user_birthday'], 0, 2); $day = substr($user['user_birthday'], 2, 2); } else if (trim(strlen($user['user_birthday'])) != 5 ) { $year = substr($user['user_birthday'], 3, 4); $month = substr($user['user_birthday'], 0, 1); $day = substr($user['user_birthday'], 1, 2); } $try->set_value('nonmandatory', 'birthday', "{$month}-{$day}-{$year}"); $try->set_value('nonmandatory', 'birthday_search', "{$year}-{$month}-{$day}"); }
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.