[PHP] "Securing PHP Web Applications" book

2009-10-20 Thread Afan Pasalic
Hi, did anybody read the book "Securing PHP Web Applications" by Tricia Ballad & William Ballad? (http://www.amazon.com/Securing-PHP-Applications-Tricia-Ballad/dp/0321534344/ref=sr_1_1?ie=UTF8&s=books&qid=1256042083&sr=8-1) Any opinions? L -- PHP General Mailing List (http://www.php.net/)

Re: [PHP] How to assign eval() to variable?

2009-05-22 Thread Afan Pasalic
short hack works like a charm! :-) thanks! afan oorza...@gmail.com wrote: short hack, assuming your eval echo's out to the browser (which I can't see how else you'd expect something to 'return' from an eval'd statement ob_start(); eval($foo); $result = ob_g

[PHP] How to assign eval() to variable?

2009-05-22 Thread Afan Pasalic
case 'website': $record = ''.$content.'; break; case 'file' require_once($file); $record = $file_content; // etc. } and it works - except eval() part. cant do $record = eval($content); ?!?!?!? thanks afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] password field validation

2009-03-12 Thread Afan Pasalic
haliphax wrote: On Thu, Mar 12, 2009 at 2:39 PM, Jason Todd Slack-Moehrle wrote: if (empty($_POST[PASSSWORD])) { $GERROR="TRUE";} If that's a direct copy/paste from your actual code, there is an extra S in PASSWORD. Also, you should enclose the array key in quotes: if (empty($_

Re: [PHP] password field validation

2009-03-12 Thread Afan Pasalic
Jochem Maas wrote: Afan Pasalic schreef: Andrew Ballard wrote: On Thu, Mar 12, 2009 at 3:05 PM, Jason Todd Slack-Moehrle wrote: Hi All, I have an input field with type="password". I am trying to do some error checking to see if the user puts a value in after t

Re: [PHP] password field validation

2009-03-12 Thread Afan Pasalic
f (empty($_POST['PASSWORD'])) { $GERROR='TRUE'; } Andrew try if trim() gives you any different result: if (empty(trim($_POST['PASSWORD']))) { $GERROR='TRUE'; } afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] multiple choice dropdown box puzzle

2009-02-23 Thread Afan Pasalic
quot; can't be part of the mysql statement, it should be "outside" the statement FOR ( $ii = 0 ; $ii < count($categoriesIN) ; $ii++ ) { $sql4 = "INSERT INTO temp (example) $categoriesIN[$ii]" ; $result4 = mysql_query

Re: [PHP] Speed Opinion

2009-02-04 Thread Afan Pasalic
each record you make a database query to table 2. in general mysql is "faster" than php. do/select as much as you can in mysql. -afan PS: I know I can use a join, but I find anytime I use a join, the database query is extremely slow, I have tried it for each version of mysql a

[PHP] is this use of subquery "smart"

2009-02-04 Thread Afan Pasalic
registrants.reg_id=r.ghost_record), 'y') as registered_by_name FROM registrants r WHERE r.org_id=12 AND r.reg_status=0 AND r.reg_id=r.person_id this way subquery will be executed "everytime", but I have everything on one place? thanks for any opinion... afan -- PHP General Mailing Lis

Re: [PHP] developers life

2009-01-19 Thread Afan Pasalic
ough its not) - lots more but lost interest / focus You just described me! :-) afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] search for person by comparing his data with data in mysql

2008-12-19 Thread Afan Pasalic
hi, I have to build a little "search" form. a visitor enters his/her personal and work data (first name, last name, email, org. name, phones (home phone, work phone, cell) home address, work address) using a form, and then administrator has to compare these data with existing data in database (

Re: [PHP] Displaying information from table graphically

2008-11-21 Thread Afan Pasalic
eds_0.gif (actually, this is a transparent 1x1 gif) images no_of_beds_1.gif images no_of_beds_2.gif images no_of_beds_3.gif images no_of_beds_4.gif $query = mysql_qurey("select no_of_beds from beds where room=123"; $result = mysql_fetch_assoc($query); echo "border=0 />"; something l

Re: [PHP] how to kill a session by closing window or tab clicking on X?

2008-10-27 Thread Afan Pasalic
Stut wrote: On 27 Oct 2008, at 14:10, Afan Pasalic wrote: I'm sorry for posting this more javascript then php question, but it's somehow php related. here is the issue: very often people close the window/tab without logging out. I need solution how to "recognize" when [x]

[PHP] how to kill a session by closing window or tab clicking on X?

2008-10-27 Thread Afan Pasalic
n before the window/tab is closed. few years ago, before firefox and tabs, I solved this by javascript and onClose() as a part of body tag. now, it doesn't work anymore. any suggestion/opinion/experience? thanks afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] web shot script

2008-10-23 Thread Afan Pasalic
Andrew Barnett wrote: Are you suggesting to create a PDF, and then convert from PDF to an image? I'm sorry. didn't get it has to be an image. Andrew 2008/10/24 Afan Pasalic <[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>> Andrew Barnett wrote: Hey

Re: [PHP] web shot script

2008-10-23 Thread Afan Pasalic
Andrew Barnett wrote: Hey Joey, I had a search, and from what I found, it would be very difficult unless you have root access to a server. Another way would be to create a HTML/CSS renderer using PHP, and then using that to take a screenshot. or, maybe, as an idea, save the page as pdf?

Re: [PHP] SESSION array problems [SOLVED]

2008-10-02 Thread Afan Pasalic
is: > > for ($i = 0; $i < $num_users; $i++) >{ >$last = $_SESSION['last_name'][$i]; >$first = $_SESSION['first_name'][$i]; >echo("$last $first"); >} > > See the difference? > > This was a crazy one. > > Now, someone s

Re: [PHP] Re: SESSION array problems UPDATE

2008-10-02 Thread Afan Pasalic
d one echo line: foreach( $_SESSION['user_id'] as $index => $value ) { echo '-> '.$index.': '.$value.''; $last_name = $_SESSION['last_name'][$index]; $first_name = $_SESSION['first_name'][$index]; echo("$index $last_name $first_name"); } thanks -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] SESSION array problems

2008-10-01 Thread Afan Pasalic
tedd wrote: > At 2:43 PM -0500 10/1/08, Afan Pasalic wrote: >> just tested. works fine >> >> >> >> $_SESSION = array( >> '6156' => array( >> 'first_name'=> 'Diane', >&

Re: [PHP] Re: SESSION array problems

2008-10-01 Thread Afan Pasalic
>> } > > Jay: > > Close, it produced: > > Array, Array > Array, Array > Array, Array > > Cheers, > > tedd then your $_SESSION is not what you think it is and print_r() output is not correct. :-) -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] SESSION array problems

2008-10-01 Thread Afan Pasalic
> array( 'first_name'=> 'Diane', 'last_name' => 'Cable'), '7030' => array( 'first_name'=> 'Fred',

Re: [PHP] SESSION array problems

2008-10-01 Thread Afan Pasalic
[first_name]=> Diane [last_name] => Cable } [7030] { [first_name]=> Fred [last_name]=> Cago } [656] { [first_name]=> Helen [last_name]=> Cahalan } } main reason - if you sort

Re: [PHP] Robert Cummings

2008-09-30 Thread Afan Pasalic
Quite often, it's offered when you don't especially > want it. Nonetheless, it's great news, and I think we should all take > a moment and wonder: why the hell aren't you at the hospital with your > wife and newborn son, Rob? ;-P > > Congrats to the Cummings family!

Re: [PHP] how to recognize CSV file?

2008-09-20 Thread Afan Pasalic
Ashley Sheridan wrote: On Fri, 2008-09-19 at 14:24 -0500, Afan Pasalic wrote: Eric Butera wrote: On Fri, Sep 19, 2008 at 3:14 PM, Afan Pasalic <[EMAIL PROTECTED]> wrote: Eric Butera wrote: On Fri, Sep 19, 2008 at 2:59 PM, Afan Pasalic <[EMAIL PROTECTED]> wrote:

Re: [PHP] how to recognize CSV file?

2008-09-19 Thread Afan Pasalic
Eric Butera wrote: > On Fri, Sep 19, 2008 at 3:14 PM, Afan Pasalic <[EMAIL PROTECTED]> wrote: > >> Eric Butera wrote: >> >>> On Fri, Sep 19, 2008 at 2:59 PM, Afan Pasalic <[EMAIL PROTECTED]> wrote: >>> >>> >>>&

[PHP] how to recognize CSV file?

2008-09-19 Thread Afan Pasalic
e']['type'] = 'text/comma-separated-values' openSuse machine and Konqueror: $_FILES['UploadedFile']['type'] = 'text/csv' ok. what's CORRECT way to validate uploaded file? thanks. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Restore Leading Zeros in Zip Codes

2008-08-22 Thread Afan Pasalic
: Why take them out in the first place? Keep the zip code as a string. After all, not all countries use just numbers. Cheers, tedd or, if you use US zip codes only, use ZEROFILL feature in mysql? -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net

Re: [PHP] FCKEditor, TinyMCE, ... I need a light weight WYSIWYG HTML Editor

2008-08-18 Thread afan pasalic
Warren Vail wrote: > A textarea is a simple editor, I am assuming you want something better than > that, or you wouldn't have looked further. > I just tried Demo and got this: "Sorry, you must have Internet Explorer 5.5 or higher to use the WYSIWYG editor" ?!? I'm

Re: [PHP] changing order of items

2008-05-15 Thread afan pasalic
Eric Butera wrote: > On Thu, May 15, 2008 at 2:49 PM, afan pasalic <[EMAIL PROTECTED]> wrote: > >> Iv Ray wrote: >> >>> afan pasalic wrote: >>> >>>> this one bugs me for a while. how to change order. >>>> >>

Re: [PHP] changing order of items

2008-05-15 Thread afan pasalic
Iv Ray wrote: > afan pasalic wrote: >> this one bugs me for a while. how to change order. >> >> I have a list of tasks. by status, task could be 1 (todo) or 0 (done) - >> status value stored in mysql. I can list tasks per status or all. >> order number is stored

[PHP] changing order of items

2008-05-15 Thread afan pasalic
g on screen (of course) before start switching places with 9, 8, 7, and 6. how do you avoid this "gap"? what solution do you use at all? thanks for any help. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] transfer list in textarea to comma delimited string

2008-05-02 Thread afan pasalic
Stut wrote: > On 2 May 2008, at 16:22, afan pasalic wrote: >> I have one textarea field in a registration form where visitor enters >> keywords. even there is a not next to the field "please enter keywords >> as comma delimited string", they enter as a list, bel

[PHP] transfer list in textarea to comma delimited string

2008-05-02 Thread afan pasalic
utions but non of them works: $keywords = eregi_replace('\n', '.', $keywords); $keywords = eregi_replace('\r', '.', $keywords); $keywords = eregi_replace('\n\r', '.', $keywords); $keywords = eregi_replace('', '.', $ke

Re: [PHP] check if any element of an array is not "empty"

2008-04-30 Thread afan pasalic
yup! that's the one :D thanks richard Richard Heyes wrote: >> but I was thinking if there is the function does that. > > array_filter(). Note this: > > "If no callback is supplied, all entries of input equal to FALSE (see > converting to boolean) will be removed." > > http://uk3.php.net/manual/

[PHP] check if any element of an array is not "empty"

2008-04-30 Thread afan pasalic
0 + $string = 0). I know I can do something like: foreach($result as $value) { if ($value !=0) { $alert = true; } } or if (in_array($result, '-')) { $alert = true; } but I was thinking if there is the function does that. thanks for any help. -afan --

Re: [PHP] need opinions regarding php.ini

2008-01-05 Thread Afan Pasalic
. Isn't is vulnerable point? -afan Daniel Brown wrote: On Jan 5, 2008 2:35 AM, Afan Pasalic <[EMAIL PROTECTED]> wrote: hi, after my host moved my account from old server (shared hosting) with php 4.4.7, mysql 4.x to new one with php 5.x and mysql 5.x. nice. they did it fast and witho

[PHP] need opinions regarding php.ini

2008-01-04 Thread Afan Pasalic
about this and they told me "that is how our system is setup": "... afan [20:25]: why is now different then before? [20:25]: That is not different. That has always been the case. You may not have had a php.ini in every folder, but every folder still needed its own php.ini i

Re: [PHP] Posting Summary for Week Ending 4 January, 2008: php-general@lists.php.net

2008-01-04 Thread Afan Pasalic
Guys, whatever you're doing, please stop. I'm getting tired deleting tons of emails for the last hour. If you testing something there is definitly other way than sending emails to all subscribers, right? Thanks. -afan PostTrack [Dan Brown] wrote: Posting Summary for P

Re: [PHP] function I created doesn't work

2008-01-04 Thread afan pasalic
Jim Lucas wrote: > afan pasalic wrote: >> Daniel Brown wrote: >>> On Jan 4, 2008 12:52 PM, afan pasalic <[EMAIL PROTECTED]> wrote: >>>> I think you didn't understand my question: I know why the function work >>>> in 2nd example. My question w

Re: [PHP] function I created doesn't work [SOLVED]

2008-01-04 Thread afan pasalic
Daniel Brown wrote: > On Jan 4, 2008 12:52 PM, afan pasalic <[EMAIL PROTECTED]> wrote: >> I think you didn't understand my question: I know why the function work >> in 2nd example. My question was why I'm not getting the result in 1st >> example? What am I

Re: [PHP] function I created doesn't work

2008-01-04 Thread afan pasalic
Daniel Brown wrote: > On Jan 4, 2008 12:52 PM, afan pasalic <[EMAIL PROTECTED]> wrote: >> I think you didn't understand my question: I know why the function work >> in 2nd example. My question was why I'm not getting the result in 1st >> example? What am I

Re: [PHP] function I created doesn't work

2008-01-04 Thread afan pasalic
Daniel Brown wrote: > On Jan 4, 2008 12:28 PM, afan pasalic <[EMAIL PROTECTED]> wrote: >> Daniel Brown wrote: >>> On Jan 4, 2008 12:06 PM, afan pasalic <[EMAIL PROTECTED]> wrote: >>>> hi >>>> I have function >>>> function get

Re: [PHP] function I created doesn't work

2008-01-04 Thread afan pasalic
27;m pulling content from table infos for specific client, form and index1. If there is no record I'm using recursive part (inside "else") to get the default value (client_id=0, form_id=0). When echo the content right before "return" I can see it. But can't see it in echo after calling the function?!?! thanks -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] function I created doesn't work

2008-01-04 Thread afan pasalic
Daniel Brown wrote: > On Jan 4, 2008 12:06 PM, afan pasalic <[EMAIL PROTECTED]> wrote: >> hi >> I have function >> function get_content($client_id, $form_id, $index1) >> { >> $query = mysql_query(" >> SE

[PHP] function I created doesn't work

2008-01-04 Thread afan pasalic
ry); $CONTENT = $result['content']; } else { get_content(0, 0, $index1); } } get_content(12, 104, 'merchant'); echo $CONTENT; # Shows correct. What's wrong with first solution? Thanks for any help. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] handling ' with mysql/php insert and select

2008-01-03 Thread afan pasalic
my > options? run every variable through stripslashes(); before printing > them to the screen? > If you have access to php.ini turn the magic_quotes_gpc off. If not, then you have to use one of examples on http://us.php.net/manual/en/function.get-magic-quotes-gpc.php -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] First stupid post of the year.

2008-01-02 Thread afan pasalic
Also (fine tuning :)), I think you don't need whole < ... style="width:160px;align:center;text-align:center;" /> Just < ... style="width:160px;" /> because it's form button and it's by default already centered. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] First stupid post of the year.

2008-01-02 Thread Afan Pasalic
-nathan -nathan: Have you tried that? I have, and it don't work. I can create wider whatever but I cannot create a wider submit button. Cheers, tedd Yes you can: -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] email authentication

2007-12-22 Thread Afan Pasalic
l client settings or contact your administrator to verify that the domain or address is defined for this server. in D:\Sites\CWIPanel\Accounts\mydomain.com\wwwroot\reservation.php on line 34 Never get such a error using LAMP. Thanks for any help, -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] [SOLVED] Why I sart getting "Fatal error: Allowed memory size..." after php upgrade?

2007-12-20 Thread afan pasalic
Richard Lynch wrote: > On Thu, December 20, 2007 11:37 am, afan pasalic wrote: >> The hosting company I have one account (and several Add Domains) >> upgraded php on the server from 4.4.7 to 5.2.5. After the upgrade I >> start getting the error message: >> Fatal er

Re: [PHP] Why I sart getting "Fatal error: Allowed memory size..." after php upgrade?

2007-12-20 Thread afan pasalic
through Fantastico and - got his message? of course, support will help him (do it for him) to edit php.ini, but it shouldn't happen at the first time, right? And, as I said, I don't want to make a big deal for hosting company because they are good and this is first time something

Re: [PHP] Why I sart getting "Fatal error: Allowed memory size..." after php upgrade?

2007-12-20 Thread afan pasalic
Richard Lynch wrote: > On Thu, December 20, 2007 11:37 am, afan pasalic wrote: >> The hosting company I have one account (and several Add Domains) >> upgraded php on the server from 4.4.7 to 5.2.5. After the upgrade I >> start getting the error message: >> Fatal er

[PHP] Why I sart getting "Fatal error: Allowed memory size..." after php upgrade?

2007-12-20 Thread afan pasalic
to hear your opinion what caused the problem. I'll edit php.ini, I'm not going to make a big deal of it, though, I just want to know why it happened. Thanks for help. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] how to recognize ENUM column in table?

2007-12-07 Thread Afan Pasalic
Jim Lucas wrote: Afan Pasalic wrote: Jim Lucas wrote: Afan Pasalic wrote: hi, I use the code from http://www.php.net/manual/en/function.mysql-fetch-field (example #1) I'm getting everything I need but can't recognize if the column is ENUM() type? e.g. column "status" is E

Re: [PHP] how to recognize ENUM column in table?

2007-12-07 Thread Afan Pasalic
Jim Lucas wrote: Afan Pasalic wrote: hi, I use the code from http://www.php.net/manual/en/function.mysql-fetch-field (example #1) I'm getting everything I need but can't recognize if the column is ENUM() type? e.g. column "status" is ENUM('0','1'

Re: [PHP] how to recognize ENUM column in table?

2007-12-06 Thread Afan Pasalic
sounds like a solution! :) thanks andrew. -afan Andrew Ballard wrote: On Dec 6, 2007 1:38 PM, Afan Pasalic <[EMAIL PROTECTED]> wrote: hi, I use the code from http://www.php.net/manual/en/function.mysql-fetch-field (example #1) I'm getting everything I need but can't

[PHP] how to recognize ENUM column in table?

2007-12-06 Thread Afan Pasalic
x27;,'archive') or something like that. I want to recognize this column and then create a form with radio buttons o 0 o 1 or o live o hidden o archive is it possible? thanks. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] checkbox unchecked

2007-12-02 Thread Afan Pasalic
I did once, if I remember once, this "strategy": > If checked, you will have value "y". Though, if unchecked, or it was checked and visitor unchecked, the value should be "n". ;) -afan Ronald Wiplinger wrote: I have now tried to add many of the security

Re: [PHP] including parenthesis, space and dashes in a phone number

2007-11-30 Thread afan pasalic
It's ok to store it this way, but it could be a little PITA when search. E.g., you store (123) 456-7890 and somebody search for 123-456-7890? Right? -afan Daevid Vincent wrote: > The kind of opposite of this, is what I use, in that it ADDs the () and - > > if ((strlen($phone))

Re: [PHP] excluding parenthesis, space and dashes from phone number

2007-11-30 Thread afan pasalic
Jochem Maas wrote: > afan pasalic wrote: >> hi, >> I store phone number in mysql as integer, e.g. (123) 456-7890 is stored >> as 1234567890. >> though, in search form they usually type in a phone number with >> parenthesis/space/dashes. I have to extract numbers

[PHP] excluding parenthesis, space and dashes from phone number

2007-11-30 Thread afan pasalic
, to do the job: eregi_replace(' ', '', $phone); eregi_replace('(', '', $phone); eregi_replace(')', '', $phone); eregi_replace('-', '', $phone); and it works fine. but, is there any better way? more "fancy&quo

[PHP] ini_set('memory_limit', '16M')

2007-11-28 Thread afan pasalic
ssage?!? Any idea? Thanks for any help. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] what is better way to write the query

2007-11-02 Thread afan pasalic
Stut wrote: > Jim Lucas wrote: >> afan pasalic wrote: >>> hi, >>> it's maybe more question for mysql list, but since php is involved >>> too... :-) >>> I have php script that inserts into mysql table couple hundreds of >>> records.

Re: [PHP] what is better way to write the query

2007-11-02 Thread afan pasalic
Stut wrote: > afan pasalic wrote: >> Stut wrote: >>> Jim Lucas wrote: >>>> afan pasalic wrote: >>>>> hi, >>>>> it's maybe more question for mysql list, but since php is involved >>>>> too... :-) >>>>>

Re: [PHP] what is better way to write the query

2007-11-02 Thread afan pasalic
timization"? sorry for "english" :-) -afan afan pasalic wrote: > hi, > it's maybe more question for mysql list, but since php is involved > too... :-) > I have php script that inserts into mysql table couple hundreds of records. > usually, it looks like: &

[PHP] what is better way to write the query

2007-11-02 Thread afan pasalic
hi, it's maybe more question for mysql list, but since php is involved too... :-) I have php script that inserts into mysql table couple hundreds of records. usually, it looks like: http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] problem calling functions

2007-10-19 Thread afan pasalic
yup! it works perfect. obviously, it's MY fault. :-) thanks stut -afan Stut wrote: > afan pasalic wrote: >> actually, what example you are talking about? I got jay's example only? > > http://dev.stut.net/php/varfunc.php > > -Stut > -- PHP General Mai

Re: [PHP] problem calling functions

2007-10-19 Thread afan pasalic
actually, what example you are talking about? I got jay's example only? Stut wrote: > afan pasalic wrote: >> why then the code doesn't work? >> the error I'm getting is: "Fatal error: Call to undefined function >> solution1() in ..." even the functi

Re: [PHP] problem calling functions

2007-10-19 Thread afan pasalic
Stut wrote: > afan pasalic wrote: >> why then the code doesn't work? >> the error I'm getting is: "Fatal error: Call to undefined function >> solution1() in ..." even the function itself is just above the line that >> calls function? > > I can

Re: [PHP] problem calling functions

2007-10-19 Thread afan pasalic
why then the code doesn't work? the error I'm getting is: "Fatal error: Call to undefined function solution1() in ..." even the function itself is just above the line that calls function? -afan Stut wrote: > Jay Blanchard wrote: >> I don't think you can put

Re: [PHP] problem calling functions

2007-10-19 Thread afan pasalic
h($function) { case 'solution1': solution1($var1); break; case 'solution2': solution2($var2); break; case 'solution3': solution3($var3); break; } ;-) -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] problem calling functions

2007-10-19 Thread afan pasalic
Jay Blanchard wrote: > [snip] > function solution1($var1){ > // some code > } > > function solution2($var2){ > // some code > } > > function solution3($var3){ > // some code > } > > if ($function == 'solution1' or $function == 'solution2' or $function == > 'solution3') > {

Re: [PHP] problem calling functions

2007-10-19 Thread afan pasalic
Robin Vickery wrote: > On 19/10/2007, afan pasalic <[EMAIL PROTECTED]> wrote: > >> hi >> I have a problem with calling functions: >> >> > function solution1($var1){ >> // some code >> } >> >> function solution2($var

[PHP] problem calling functions

2007-10-19 Thread afan pasalic
hi I have a problem with calling functions: suggestions? thanks. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Reload page after form submit

2007-08-31 Thread Afan Pasalic
method POST is submitted. if you open the page first time "else" block will be executed. though, I agree it's much better to have if(isset($_POST['SubmitForm']) and $_POST['SubmitForm'] == 'Submit') where but, as I said earlier, it's not

Re: [PHP] Reload page after form submit

2007-08-30 Thread Afan Pasalic
z "); $result = mysql_fetch_array($query, MYSQL_ASSOC); $first = $result['first']; $last = $result['last']; } ?> First: Last: -afan From: "Wagner Garcia Campagner" <[EMAIL PROTECTED]> Hello, I'm building a web p

Re: [PHP] OT- why is network solutions more than godaddy?

2007-08-03 Thread Afan Pasalic
I'm with GoDaddy since 1999 and have over 60 domains. Never had a problem with them. -afan Stut wrote: blackwater dev wrote: I have to register a bunch of names and am trying to figure out why I would pay $35 when I can just pay $9 at godaddy. Does godaddy own it and I lease it from

Re: [PHP] register_globals and magic_quotes_gpc (again)

2007-06-07 Thread Afan Pasalic
Tijnema wrote: On 6/7/07, Afan Pasalic <[EMAIL PROTECTED]> wrote: hi, this question is already posted thousand times. but, after I tried for 2 hours to figure it out, I gave up and posted the question here. I'm rebuilding one site. php 4.4.4 as usual, register_globals on,

[PHP] register_globals and magic_quotes_gpc (again)

2007-06-06 Thread Afan Pasalic
l1332 AuthUserFile /u/web/afan/_vti_pvt/service.pwd AuthGroupFile /u/web/afan/_vti_pvt/service.grp and I tried to add php_flag register_globals Off and it doesn't work (500 internal server error) I tried with register_global 0 - same thing. could you please point me where to look after? thanks fo

Re: [PHP] Re: find (matching) person in other table

2007-05-31 Thread Afan Pasalic
David Giragosian wrote: On 5/31/07, Afan Pasalic <[EMAIL PROTECTED]> wrote: Jared Farrish wrote: > On 5/30/07, Afan Pasalic <[EMAIL PROTECTED]> wrote: > email has to match "in total". [EMAIL PROTECTED] and [EMAIL PROTECTED] >> are NOT the same in my case.

Re: [PHP] Re: find (matching) person in other table

2007-05-31 Thread Afan Pasalic
Jared Farrish wrote: On 5/30/07, Afan Pasalic <[EMAIL PROTECTED]> wrote: email has to match "in total". [EMAIL PROTECTED] and [EMAIL PROTECTED] are NOT the same in my case. thanks jared, If you can match a person by their email, why not just SELECT by email only (and re

Re: [PHP] Re: find (matching) person in other table

2007-05-30 Thread Afan Pasalic
Jared Farrish wrote: On 5/30/07, Afan Pasalic <[EMAIL PROTECTED]> wrote: yes. in one hand it's more for mysql list. though, I was thinking more if somebody had already something similar as a "project". more as path I have to follow. e.g., in your example, in where cl

Re: [PHP] find (matching) person in other table

2007-05-30 Thread Afan Pasalic
Richard Lynch wrote: On Wed, May 30, 2007 3:30 pm, Afan Pasalic wrote: hi, the code I'm working on has to compare entered info from registration form with data in members table and list to administrator (my client) all "matching" people. admin then has to decide is person

Re: [PHP] Re: find (matching) person in other table

2007-05-30 Thread Afan Pasalic
Jared Farrish wrote: I was thinking to assign points (percentage) to matching fields (last name, first name, email, phone, city, zip, phone) and then list people with more than 50%. e.g., if first and last name match - 75%, if only email match - 85%, if first name, last name and email match - 100

[PHP] find (matching) person in other table

2007-05-30 Thread Afan Pasalic
, last name and email match - 100%, if last name and phone match - 50%... etc. does anybody have any experience with such a problem? or something similar? thanks for any help. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] error_reporting(E_ALL) doesn't show anything

2007-05-15 Thread Afan Pasalic
Stut wrote: Please include the list in replies. I'm sorry. Clicked on wrong Reply button :-) Afan Pasalic wrote: Stut wrote: Afan Pasalic wrote: in php.ini is error_reporting turned off. and, to see an error have to open error_log. though, for me is much easier to have it on and se

[PHP] error_reporting(E_ALL) doesn't show anything

2007-05-15 Thread Afan Pasalic
it doesn't work. still can't see anything. what am I doing wrong? thanks. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Need a new shared host with php

2007-05-10 Thread Afan Pasalic
similar before) but it doesn't bother me a lot. Agree with Edward, VPS is better solution - if possible. I used pair.com for a while. Pricey but VERY GOOD. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] isset

2007-04-16 Thread Afan Pasalic
that was actually my point. :) -afan Stut wrote: tedd wrote: At 4:08 PM +0100 4/16/07, Stut wrote: Jim Lucas wrote: Richard Kurth wrote: What do you do when isset does not work? If I send data in a $_REQUEST['var'] like if (isset($_REQUEST['var'])) { } Put var has no d

Re: [PHP] isset

2007-04-15 Thread afan
> Afan Pasalic wrote: >> >> Jochem Maas wrote: >>> Richard Kurth wrote: >>> >>>> What do you do when isset does not work? If I send data in a >>>> $_REQUEST['var'] like >>>> if (isset($_REQUEST['var&#

Re: [PHP] how to get var name and value from function?

2007-04-14 Thread Afan Pasalic
Tijnema ! wrote: > On 4/14/07, Afan Pasalic <[EMAIL PROTECTED]> wrote: >> hi, >> this one I can't figure out: >> >> I have to assign value of an array to variable named after key of the >> array several times in my project to , e.g. after I submit a

[PHP] how to get var name and value from function?

2007-04-13 Thread Afan Pasalic
.''; // to test results and seeing array variables and values } } value2var($_POST, 1); but, I don't know how to get info from function back to script?!?!? :-( any help appreciated. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] PHP editor

2007-04-11 Thread afan
http://www.estrintech.com > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > On both Win and Linux I use Zend Studio. Not free but it's worth every cent. Before I used HomeSite. Great tool too. If you use Linux Quanta+ is great tool too. Download EVERY editor you think and try it. What I like doesn't mean it's ok with you. Try even not free editors - it's worth testing, and you will find what do you really want from an editor. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] mysql if empty

2007-04-09 Thread afan
#x27;"; > > $result = mysql_query($sql); > > if ($result == "") > { > echo "No result found"; > } > echo "Found"; try this: $sql = "SELECT Client FROM booked WHERE Name = 'larry'"; $result = mysql_query($sql); if(mysql_num_rows(

Re: [PHP] Idea/Suggestion for PHP App

2007-04-07 Thread Afan Pasalic
dy have the code you can reuse), a sketch/outline of the application's architecture/structure with a paper and a pencil is time saving. :) -afan tedd wrote: At 9:59 PM +0200 4/5/07, [EMAIL PROTECTED] wrote: and yes, I (still) use paper and pencil because never find good app for it. if yo

Re: [PHP] PHP has encountered an Access Violation at 01F13157?!?!?!?

2007-04-07 Thread Afan Pasalic
already did. though, my "expertize" is telling me: install php4 instead php5 :D Tijnema ! wrote: On 4/7/07, Tijnema ! <[EMAIL PROTECTED]> wrote: On 4/7/07, Afan Pasalic <[EMAIL PROTECTED]> wrote: > hi, > I just installed php 5.2.1-win32-installer on win

Re: [PHP] PHP has encountered an Access Violation at 01F13157?!?!?!?

2007-04-07 Thread Afan Pasalic
use IIS. Tijnema ! wrote: On 4/7/07, Afan Pasalic <[EMAIL PROTECTED]> wrote: hi, I just installed php 5.2.1-win32-installer on win box (XP). use IIS. created index.html file and localhost/index.html is ok. created phpinfo.php (with only phpinfo()) and was ok. then installed Zend 5.5.

[PHP] PHP has encountered an Access Violation at 01F13157?!?!?!?

2007-04-06 Thread Afan Pasalic
message from subject line. according google and php.net, it's bug?!? any idea? thanks for any help. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Idea/Suggestion for PHP App

2007-04-05 Thread afan
never find good app for it. if you can recommend - I'll be more than happy to use it and stop wasting paper (agree with you on "poor tree" :D) -afan > Cheers, > Rob. > -- > .. > | InterJinn Application Framewor

Re: [PHP] Idea/Suggestion for PHP App

2007-04-05 Thread afan
first step is: take a paper and pen and start drawing your app structure in blocks. once you "finished your app" on the paper start drawing db structure. start coding after you have the solution for every situation. :D -afan > Hey... I am new to the list so please forgive me if I

  1   2   3   >