[PHP] register_shutdown_function
im trying to make a distructor for a mysql class to kill the connection when the object is destroyed using register_shutdown_function(~xmysql); if i put that in my class will it do that or am i getting confused. ~xmysql is a destructor function i made. Heres the code, will it work how i want it to? class xmysql { var $id; register_shutdown_function(~xmysql); function xmysql() { $id = mysql_connect(localhost,'mystic','cqr73chw'); or die(Could not connect to MYSQL database); } function ~xmysql() { mysql_close($id); } function GetID() { return $id; } } // end xmysql -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Re: Need row number from database select
I see what you are trying to do David but that was what I tried first but it doesn't work because the function calls itself depending if it's not a parent so the alternating colors become all messed up depending on the structure of my folders. That's why I was hoping to get the number for each of the result returned so I could change the color depending if it was odd or even. Any other suggestions? -Original Message- From: David Robley [mailto:[EMAIL PROTECTED]] Sent: April 14, 2002 6:50 PM To: [EMAIL PROTECTED] Subject: RE: [PHP] Re: Need row number from database select Well, you don't need to know what row number is. Something like: function build_folder_tree($output, $parent=1, $indent=) { $color = red; // Set var to first option $qid = mysql_query(SELECT id, name FROM folders WHERE parent_id = $parent); while ($cat = mysql_fetch_object($qid)) { $output .= $cat-name + $indent; // here is where I want to assign diff. colors $color == red ? $color = blue: $color = red; // Cycle color for each iteration if ($cat-id != $parent) build_folder_tree($output, $cat-id, $indent.nbsp;nbsp;); } } -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] graphing packages
On Monday 15 April 2002 07:14, Christian Calloway wrote: hey ppl, I need to create some fairly complex graphs dynamically, and I need to be able to specify line, bar, or pie charts. Are there any PHP packages that someone could point me to that would fill my needs. Thanks There is jpgraph. Also take a look in www.phpclasses.org. -- Jason Wong - Gremlins Associates - www.gremlins.com.hk Open Source Software Systems Integrators * Web Design Hosting * Internet Intranet Applications Development * /* Please keep your hands off the secretary's reproducing equipment. */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] phpMyAdmin protection
Hey PHP General List, Can anybody point me to tutorial or real good explanation site how to keep Http://localhost/phpmyadmin off for other users. I am using it to help me with MySQL database but other peaople can access it. I know there is something with .httacces but i dont know anything about that .httacces. SO please if anybody can point me to some explanation how to secure phpmyadmin or just explain bu them selves. Thank You. :--: Have A Nice Day! Mantas Kriauciunas A.k.A mNTKz Contacts: [EMAIL PROTECTED] Http://mntkz-hata.visiems.lt -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] first time user
thank's again , seems i'm too far still a newbie that the hints you gave me give me a headache and don't let me succeed, if you have the spare time, have a look yourself, i have everything attached, an online copy can be seen at www.janusfoundation.org/test/navigations-testpage.htm. the relevant lines for the links are inside the file stars_array.js on line 162 and 163. maybe you could also recommend a good book for me that explains php for dummies (if you know one in german, even better). thanks coo p.s : i have 3 files attached , 2 here and the 3rd in the follow up because the mailserver doesn't take more than 40kb. begin 666 stars_array.js M+R\@36EL;VYI8R!$2%1-3!-96YU#0HO+R!P;5AV4;F]T92!T:%T(UA M:F]R(-H86YG97,=\@=AIR!F:6QE(AA=F4@8F5E;B!M861E+@T*+R\- MB\O(%EO=2!N;R!L;VYG97(;F5E9!T;R!N=6UB97(6]UB!M96YUR!A MR!I;B!PF5V:6]UR!V97)S:6]NRX@#0HO+R!4:4;F5W(UE;G4W1R M=6-T=7)E(%L;]WR!Y;W4@=\;F%M92!T:4;65N=2!I;G-T96%D+B!4 M:ES(UE86YS('1H8706]U('1O(')E;6]V92!M96YUR!A;F0;F]T()R M96%K('1H92!S7-T96TN#0HO+R!4:4W1R=6-T=7)E('-H;W5L9!A;'-O M()E(UU8V96%S:65R('1O(UO9EF2P@861D(8F5M;W9E(UE;G5S M(%N9!M96YU(ET96US+@T*+R\#0HO+R!)9B!Y;W4@87)E(AA=FEN9R!D M:69F:6-U;'1Y('=I==AE(UE;G4QE87-E(')E860@=AE($9!42!A M=!H='1P.B\O=W=W+FUI;]N:6,N8V\N=6LO;65N=2]F87$NAP()E9F]R M92!C;VYT86-T:6YG('5S+@T*+R\-B\O(%!L96%S92!N;W1E('1H870@=AE M(%B;W9E('1E'0@0T%.()E(5R87-E9!I9B!Y;W4@=VES:X-T*#0H- MT*+R\@5AE(9O;QO=VEN9R!L:6YE(ES(-R:71I8V%L(9OB!M96YU M(]P97)A=EO;BP@86YD(UUW0@87!P96%R(]N;'D;VYC92X-FUE;G5N M=6T],#MM96YUSUN9707)R87DH*3M?9#UD;V-U;65N=#MF=6YC=EO;B!A M91M96YU*E[;65N=6YU;2LK.VUE;G5S6VUE;G5N=6U=/6UE;G4[?69U;F-T M:6]N(1U;7!M96YUR@IVUT/2(\V-R:7!T(QA;F=U86=E/6IA=F%S8W)I M'0^(CMF;W(H83TQ.V$\;65N=7,N;5N9W1H.V$K*RE[;70K/2(;65N=2(K M82LB/6UE;G5S6R(K82LB73LB?6UT*STB/%POV-R:7!T/B([7V0N=W)I=4H M;70I?0T*+R]0;5AV4;5A=F4@=AE(%B;W9E(QI;F4:6YT86-T#0H- MB\O+R\O+R\O+R\O+R\O+R\O+R\O+R\O+R\O+R\O+R\O+R\O+PT*+R\@161I M=%B;4')O5R=EER!35$%25!H97)E(\O#0HO+R\O+R\O+R\O+R\O M+R\O+R\O+R\O+R\O+R\O+R\O+R\O+R\-T*#0IT:6UE9V%P/34P, D)0DO M+R!4:4@=EM92!D96QA2!F;W(;65N=7,=\F5M86EN('9IVEB;4- MF9O;QO=W-P965D/34)0DO+R!;VQL;W4V-R;VQL:6YG('-P965D#0IF M;VQL;W=R871E/30P0D)+R\@1F]L;]W(%-CF]L;EN9R!2871E#0IS=6)O M9F9S971?=]P/3(P.PD)+R\@4W5B(UE;G4;V9FV5T(%1O!P;W-I=EO M;B -G-U8F]F9G-E=%]L969T/3$P.PD)+R\@4W5B(UE;G4;V9FV5T($QE M9G0]S:71I;VX-T*#0IS='EL93$]6R ( ( ( ( ( O+R!- M96YU(%!R;W!EG1I97,07)R87D-B).65D9# B+ ( ( ( ( M(\O($]F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0D)2\O(%!R;W!EG1I97,07)R87D@+2!T:ES(ES('-E M=!H:6=H97(=7 L(%S(%B;W9E#0HQ+ D)0D)0DO+R!!;'=A7,5FES M:6)L92 M(%L;]WR!T:4;65N=2!I=5M('1O()E('9IVEB;4@870 M86QL('1I;64-B)L969T(BP)0D)0DO+R!!;EG;FUE;G0@+2!S971S('1H M92!M96YU(5L96UE;G1S(%L:6=N;65N=P@2%1-3!V86QU97,87)E('9A M;ED(AEF4@9F]R(5X86UP;4Z(QE9G0L(')I9VAT(]R(-E;G1ET*
[PHP] Re: Empty Delimiter error
Rich Pinder [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Let me try again: This line of the script: if (!stristr($lines[$key], $email)) { yields the following error: Warning: Empty delimiter in /home/sites/site56/web. Do you know what causes this error ? Thanks r My guess is that $email is empty (or possibly $lines[$key]). The documentation for stristr says nothing about generating warnings on such an occurance, but it would make sense. If your script can handle $email being empty, simply adjust your level of error-reporting or silence the warning with an @. Otherwise, fix whatever it is that's causing $email to be empty. -- Daniel Grace -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] first time user
thank's again , seems i'm too much of a newbie that the hints you gave me give me a headache and don't let me succeed, if you have the spare time, have a look yourself, i have everything attached, an online copy can be seen at www.janusfoundation.org/test/navigations-testpage.htm. the relevant lines for the links are inside the file stars_array.js on line 162 and 163. maybe you could also recommend a good book for me that explains php for dummies (if you know one in german, even better). thanks coo p.s : i have 3 files attached , 2 here and the 3rd in the follow up because the mailserver doesn't take more than 40kb. begin 666 navigations-testpage.htm M/AT;6P^#0H\:5A9#X-CQT:71L93YN879I9V%T:6]N('1EW1P86=E/]T M:71L93X-CQM971A(AT=' M97%U:78](D-O;G1E;G0M5'EP92(8V]N=5N M=#TB=5X=]H=UL.R!C:%RV5T/6ES;RTX.#4Y+3$B/T*/$@1$A434P M365N=2!V97)S:6]N(#,N, H8F5T82D@=W)I='1E;B!B2!!;F1Y(%=O;VQL M97DN($-O'ER:6=H= R,# Q($%N9'D@5V]O;QE2X@06QL(%)I9VATR!2 M97-EG9E9XA/T*/]H96%D/T*#0H\8F]D2!B9V-O;]R/2(C,# P,# P M(B!T97AT/2(C.3DY.3DY(B!L969T;6%R9VEN/2(P(B!T;W!M87)G:6X](C B M/T*/' ^( T*#0H(#Q30U))4%0;%N9W5A9V4]2F%V85-CFEP=!SF,] M(FEM86=EU]S86UP;5?87)R87DN:G,B('1Y4]=5X=]J879AV-R:7!T M/CPO4T-225!4/T*( \4T-225!4(QA;F=U86=E/4IA=F%38W)I'0W)C M/2)M;65N=2YJR(='EP93UT97AT+VIA=F%S8W)I'0^/]30U))4%0^#0H\ M+W ^#0H-CQA(YA;64](D%N8VAOB(^/]A/B -CQT86)L92!C96QL%D M9EN9STB,(8V5L;'-P86-I;F](C B()OF1ECTB,(=VED=](CS M,(^#0H(#QTCX@#0H( /'1D(AE:6=H=#TB,3 B/CPO=0^#0H(#PO M='(^#0H(#QTCX@#0H( /'1D/CQI;6W)C/2)'F%P:ECR]TF%N MW!AF5N=YG:68B('=I9'1H/2(R-#(B(AE:6=H=#TB,34B/CPO=0^#0H M( /'1D(')O=W-P86X](C(B(%L:6=N/2)C96YT97(B/CQI;6W)C/2)F M:6QE.B\O+T1\+S%?0V]O:VEEU=E8G=OFMS+S%?4VET97,O,5]*04Y54R]P M:7@O=UJ86YURYG:68B('=I9'1H/3(U-R!H96EG:'0],S 8F]R95R/3 M86QT/2)!8F]U=!*04Y54R!;W5N9%T:6]N(CX\+W1D/T*( \+W1R/T* M( \='(^( T*( (#QT9#XF;F)S#L\+W1D/T*( \+W1R/T*( \='(^ M( T*( (#QT9!V86QI9VX](G1O(^/)R/T*( (#PO=0^#0H( M/'1D('9A;EG;CTB=]P(B!A;EG;CTB8V5N=5R(B!R;W=S%N/2(R(CX M#0H( ( \=%B;4@8V5L;'!A91I;F](C B(-E;QS%C:6YG/2(P M(B!B;W)D97(](C B/T*( ( ( \='(^( T*( ( ( (#QT9!H M96EG:'0](C(P(CX\+W1D/T*( ( ( \+W1R/T*( ( ( \='(^ M( T*( ( ( (#QT9!W:61T:#TB-3 P(B!C;VQS%N/2(R(CX@#0H M( ( ( ( \9EV(%L:6=N/2)J=7-T:69Y(CX/9O;G0@9F%C93TB M87)I86PL(AE;'9E=EC82(VEZ93TB,B(8V]L;W(](B-.45$1# B/B - MB ( ( ( ( 5AE($I!3E53($9O=6YD871I;VX:7,86X:6YT M97)N871I;VYA;P@8VAAFET86)L92!OF=A;FES871I;VX@#0H( ( M( ( ('1H870@=V%S(9O=6YD960:6X@4W=I='IEFQA;F0@86YD(AA MR!A9F9I;EA=5S(EN($=EFUA;GDL($)E;EZ92 -B ( ( ( M( 86YD('1H92!5;FET960@4W1A=5S+B!4:4@9F]U;F1A=EO;B!D;V5S M(YO=!P=7)S=64')O9FET(]R( T*( ( ( ( (!S96QF+6EN M=5R97-T+B \8G(^#0H( ( ( ( (#QBCX-B ( ( ( M( 26X@8V]O5R871I;VX@=VET:!G;W9EFYM96YT(%N9!N;VXM9V]V M97)N;65N=%L(]R9V%N:7-A=EO;G,#0H( ( ( ( (EN(1E M=F5L;W!I;F8V]U;G1R:65S+!*04Y54R!CF5A=5S('!R;V=R86US+!P MF]M;W1ER!A;F0@97AE8W5T97,#0H( ( ( ( (5D=6-A=EO M;F%L(UE87-UF5S(%N9!PF]J96-TR!AR!W96QL(%S(')EV5AF-H M('1H870@9W5AF%N=5E( T*( ( ( ( (!T:4;VYG;VEN9R!A M=V%R96YEW,86YD(1E=F5L;W!M96YT(]F(5N=FER;VYM96YT86P@86YD M('-O8VEA; -B ( ( ( ( 8V%UV5S+B!!;6]N9R!I=',;6%N M2!E;F1E879OG,L('1H92!*04Y54R!;W5N9%T:6]N(-A;7!A:6=NR - MB ( ( ( ( 86YD('1A:V5S(%C=EO;G,9F]R(')E9F]R97-T M871I;VX@86YD(')E9V5N97)A=EO;B!O9B!N871I=F4@9F]R97-TR -B M( ( ( ( 86YD(')A:6YF;W)EW0@87)E87,=VAI;4W5P]R M=EN9R!T:4')O=5C=EO;B!O9B!EES=5N= -B ( ( ( M( :%B:71A=!F;W(;F%T:79E(%N:6UA;!S5C:65S+CQBCX-B M( ( ( ( /)R/T*( ( ( ( (!*04Y54R!IR!PF5S M96YT;'DF5A;EZ:6YG(%N(5N=FER;VYM96YT86P@86YD('-O8VEA;!P MF]J96-T( T*( ( ( ( (!I;B!96QIF4L($-E;G1R86P@06UE MFEC82P@=VAEF4@=AE($I!3E53(-OFYEG-T;VYER!AF4@8F5I;F M#0H( ( ( ( (EMQE;65N=5D(%S(UO95L(%C=EV:71I M97,N(%1H92!R97-U;'1S(EN('1H97-E('9AFEO=7,87)E87,#0H( M( ( ( (%R92!B96EN9R!E=F%L=6%T960@86YD(=E;F5R86QIF5D M('-O('1H870@=AE2!C86X@8F4=')A;G-F97)R960@#0H( ( ( M( ('1O(]T:5R(-O=6YTFEER!W:71H('-I;6EL87(8V]N9ET:6]N MR!A;F0@8V]RF5S]N9EN9R!AF5AR -B ( ( ( ( 87, M:6X@0F5L:7IE+B \+V9O;G0^/]D:78^#0H( ( ( /]T9#X-B M( ( /]TCX-B ( ( /'1R/B -B ( ( ( \=0:5I M9VAT/2(T-2(^/]T9#X-B ( ( /]TCX-B ( ( /'1R/B - MB ( ( ( \=0^/EM9R!SF,](F9I;4Z+R\O1'PO,5]#;V]K:65S M5V5B=V]R:W,O,5]3:71ER\Q7TI!3E53+W!I]S5E8V@N9VEF(B!W:61T M:#TQ,#8:5I9VAT/3(R()OF1ECTP/CPO=0^#0H( ( (#PO='(^ M#0H( ( (#QTCX@#0H( ( ( /'1D/B \9F]N=!F86-E/2)A MFEA;P:5L=F5T:6-A(B!S:7IE/2(R(B!C;VQOCTB(T8Y141$,(^(#QB MCX-B ( ( ( (%1H:7,QA;F5T(ES('5N:7%U92X\8G(^#0H M( ( ( (!4:4W!A8V4@97AP;]R97)S('1H870@=FEE=V5D(ET M(9R;VT@86)O=F4\8G(^#0H( ( ( (!M87)V96QE9!A=!W:%T M('1H97DV%W+CQBCX-B ( ( ( (#QBCX-B ( ( ( M($=O:6YG('1HF]U9V;EF93QBCX-B ( ( ( (1A2!B2!D M87D\8G(^#0H( ( ( (!W92!S96QD;VTF5A;EZ92!T:4@=]U M8VAI;F8F5A=71Y/)R/T*( ( ( ( ;V8@=AE($5AG1H/)R M/T*( ( ( ( /)R/T*( ( ( ( 3]O:VEN9R!A=!I M=!FF]M(]U=5R('-P86-E/)R/T*( ( ( ( :70:7,8G)E M871H=%K:6YG+CQBCX-B ( ( ( (#QBCX-B ( ( ( M(%1O('-E92!T:4;6]T:6]N(%N9!S:%P97,;V8@=AE(-L;W5DSQB MCX-B ( ( ( (%S(QI=FEN9R!T:EN9W,L(UE86YD97)I;F M=AR;W5G:!T:4V5A(]F(%ICQBCX-B ( ( ( (#QBCX- MB ( ( ( ('1O(-O;64@9]W;B!A;F0:%V92!A(-L;W-EB!L M;V]K/)R/T*( ( ( ( 86YD('=A=-H(AO=R!T:4:7-L86YD MR!A;F0@8V]AW1L:6YER!D86YC93QBCX-B ( ( ( ('=I= M=AE(1E97
Re: [PHP] first time user
here just the other file that makes up the menu begin 666 mmenu.js M+RH-B!$2%1-3!-96YU('9EG-I;VX@,RXS+C$X#0H@5W)I='1E;B!B2!! M;F1Y(%=O;VQL97D-B!#;W!YFEG:'0@,C P,B H8RD@36EL;VYI8R!3;VQU M=EO;G,N($%L;!2:6=H=',@4F5S97)V960N#0H@5FES=!H='1P.B\O=W=W M+FUI;]N:6,N8V\N=6LO;65N=2!OB!%;6%I;!M96YU,T!M:6QO;FEC+F-O M;0T*(%EO=2!M87D@=7-E('1H:7,@;65N=2!O;B!Y;W5R('=E8B!S:71E(9R M964@;V8@8VAAF=E(%S(QO;F@87,@6]U(EN9F]R;2!UR!O9B!Y;W5R M(EN=5N=EO;G,@=VET:!Y;W5R(%523!!3D0-B!9;W4@QA8V4@82!L M:6YK('1O(AT=' Z+R]W=WN;6EL;VYI8RYC;RYU:R]M96YU($%.1!!3$P@ M8V]P7)I9VAT(YO=EC97,@F5M86EN(EN('!L86-E(EN(%L;!F:6QE MR!I;F-L=61I;F@6]UB!H;VUE('!A9V4-B!#;VUEF-I86P@;EC96YS M97,@86YD('-U'!OG0@8V]N=')A8W1S(%R92!A=F%I;%B;4@;VX@F5Q M=65S=X-BHO#0I-=EM97(]V5T5EM96]U=@BVES*DB+#DY.3DI.U]D M/61O8W5M96YT.W-M8STM,3M-3]A95D/3 [#0INS0]*%]D+FQA65RRD_ M=')U93IF86QS90T*;G,V/2AN879I9V%T;W(N=7-ED%G96YT+FEN95X3V8H M(D=E8VMO(BDA/2TQ*3]TG5E.F9A;'-E#0IM86,]*YA=FEG871OBYA'!6 M97)S:6]N+FEN95X3V8H(DUA8R(I(3TM,2D_=')U93IF86QS90T*:68H;G,V M?'QNS0I;6%C/69A;'-E#0IO5R83TH;F%V:6=A=]R+G5S97)!9V5N=YI M;F1E$]F*)/5R82(I(3TM,2D_=')U93IF86QS90T*;G,V,3TH%RV5) M;G0H;F%V:6=A=]R+G!R;V1U8W13=6(I/CTR,# Q,#R-BD_=')U93IF86QS M90T*:64T/2@A7V0N9V5T16QE;65N=$)Y260F)E]D+F%L;D_=')U93IF86QS M93L-FMO;G$]*YA=FEG871OBYUV5R06=E;G0N:6YD97A/9B@B2V]N75E MF]R(BDA/2TQ*3]TG5E.F9A;'-E#0IM#TH;G,V*3\B]I;G1EB(Z(FAA M;F0B.V]A=]P/3 [86QE9G0],#MO86QE9G0],3MOWD],#MO=W]+3$[;W=H M/2TQ.V9RSTP.V9R93TP.VYS;6%T8V@],#L-G9AB!A+%M+]A+EM+]M M+9L=$[:QAG(];F5W($%RF%Y*D[:QC;G0],#MH;P],#M-;F%M93UN M97@07)R87DH*3MP87)R/6YE=R!!G)A[EMAIL PROTECTED]*=EM;STP.V5L/3 [;G-H M;#TP.W9AB!O;78],#MD9CTQ.VEM/3 [;V9R86,],#MO;6YU/3 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8V]L;W(](B(K
Re: [PHP] the document contained no data
Thanks Nick and Martin, the code is ok but it doen't run in Solaris (unix) with nobody, I test the code in Linux and run as I want. I work around the problem in Solaris by using EXEC() command. I may need to investigate how to get running in Unix by using REDDIR(). Thanks Nick Richardson wrote: The fact that there's a seg fault involved makes me think that's it's not so much a problem w/ code, but a problem with either apache (or whatever web server you use) a/o your PHP installation - PHP may be seg faulting before it's done reading the data from the directory and apache is reporting that no data was sent but the parser has stopped responding and is what it thinks is done. Could also be that the user apache runs under doesn't have access to that directory. Or i could be completley wrong too... who knows ;) //Nick -Original Message- From: Martin Towell [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 11, 2002 10:43 PM To: 'Phieu Huynh' Cc: [EMAIL PROTECTED] Subject: RE: [PHP] the document contained Martin Towell wrote: does that code work if you set the directory path to ./ ? -Original Message- From: Phieu Huynh [mailto:[EMAIL PROTECTED]] Sent: Friday, April 12, 2002 3:33 PM To: Martin Towell Cc: [EMAIL PROTECTED] Subject: Re: [PHP] the document contained no data I also try the following code and still have the same problem. I am runing php4.0.?, solaris(linux) $dir_name = /export/home/phuynh/php/main/student/upload/; $dir = opendir($dir_name); while (false !== ($file_names = readdir($dir))) { echo $file_names; } closedir($dir); Martin Towell wrote: odd, I copied your code, changed the dir to ./ and it works for me (php4.0.?, winnt) if dir() doesn't work for you, you might need to use opendir(), readdir(), etc -Original Message- From: Phieu Huynh [mailto:[EMAIL PROTECTED]] Sent: Friday, April 12, 2002 2:14 PM To: Martin Towell; [EMAIL PROTECTED] Subject: Re: [PHP] the document contained no data Sorry, the file has ; I retype it wrong, I did set error_reporting but no change, but in the httpd error log file I found exit signal segmentation fault (11) -- Phieu (phil) Huynh Computer System Officer Monash University Electrical Computer Systems Engineering Phone : +61 3 990 53469 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: graphing packages
Crystal Reports? Christian Calloway [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... hey ppl, I need to create some fairly complex graphs dynamically, and I need to be able to specify line, bar, or pie charts. Are there any PHP packages that someone could point me to that would fill my needs. Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] graphing packages
http://www.php.net/manual/en/ref.image.php user comments have a lot of stuff about compling GD issues then php builder has some working tutorials like this one http://www.phpbuilder.com/columns/wiesendanger20001218.php3 i was able to take the code from it code and plug in into a dynamic situation without much ado R hey ppl, I need to create some fairly complex graphs dynamically, and I need to be able to specify line, bar, or pie charts. Are there any PHP packages that someone could point me to that would fill my needs. Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] graphing packages
Try jpgraph On Sun, 14 Apr 2002, Christian Calloway wrote: hey ppl, I need to create some fairly complex graphs dynamically, and I need to be able to specify line, bar, or pie charts. Are there any PHP packages that someone could point me to that would fill my needs. Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Binding to LDAP/SASL w/PHP
I have an OpenLDAP 2.0.23 installation running with SASL 1.5.27 to support a Cyrus IMAP/Postfix mail server. I would like to work with the LDAP directory with PHP 4.1.2. I have another LDAP directory without SASL that I can bind to with PHP without any problem (all the same versions). For some reason, it won't let me bind to the LDAP w/SASL giving me a Warning: LDAP: Unable to bind to server: Inappropriate authentication error and pointing to the line where I specify the password to bind with. I've triple checked my settings and rebuilt the PHP with LDAP libraries compiled for SASL and can't find anything. I can use the standard set of ldap tools (ldapadd, ldapmodify, etc) locally on the LDAP/SASL machine with the same root dn and root password I am trying to use with PHP. Is anyone using OpenLDAP, SASL and PHP? Since the root password is commented out and carried in SASL, and the root dn is in a different format (uid=myadmin + realm=myrealm), might there be a different syntax I should use my PHP commands? Anyone have any ideas? Any help would be very much appreciated! Quinn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] graphing packages
Never used any of these, but probably what you're looking for: http://www.zend.com/codex.php?CID=345 http://www.hotscripts.com/PHP/Scripts_and_Programs/Graphs_and_Charts/ olinux --- Christian Calloway [EMAIL PROTECTED] wrote: hey ppl, I need to create some fairly complex graphs dynamically, and I need to be able to specify line, bar, or pie charts. Are there any PHP packages that someone could point me to that would fill my needs. Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] make a set of variables available to all visitors?
Actually the static variables will be used to make the query. ie I want these static variables to be used so that my url can be transformed into a numeric reference for the db query website.com/finance/ finance gets parsed out of URL to be used in where condition $article_type = array(news = 1,opinion = 2,finance = 3); $sql = SELECT * FROM articles WHERE article_type = '2'; /* where condition will contain other criteria as well (date/region) */ olinux --- Cal Evans [EMAIL PROTECTED] wrote: Actually, if they are static variables that rarely or never change, I would stick with the include file. It's faster than making a database connection and selecting them. =C= * * Cal Evans * Journeyman Programmer * Techno-Mage * http://www.calevans.com * -Original Message- From: olinux [mailto:[EMAIL PROTECTED]] Sent: Sunday, April 14, 2002 11:40 AM To: [EMAIL PROTECTED] Subject: [PHP] make a set of variables available to all visitors? What would be the best way to make a set of variables available to all visitors? example: if I stick all variables in a separate file and include - include(settings.php); - that works fine. seems that this is a lot of overhead to include these on every page. These variables would never change (they basically turn an alpha string into numeric to speed up queries.) I don't think hard coding would be a great solution either... simplified example: one set of variables to be included on all pages refer to the article type - i would like to use urls that make sense to the visitor rather than number strings so - $article_type = array(news = 1,opinion = 2,finance = 3); Maybe it would be best to simply query for WHERE article_type = 'news' etc. Thanks much, olinux __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Help on dealing with arrays of HTTP_POST vars
Hello All, I have developed a system to retrieve data from a table. The interface is a dynamic list of orders created from a query on the database that shows all the new orders. Next to each is a checkbox. Each checkbox has as its value the order number and is called PED1, PED2, PED3,PEDn, depending on how many new orders are available. If the user wants to access these orders he has to check the orders he wants and click the submit button. Once it is submited, it searches all the PED# variables on the HTTP_POST_VARS and builds an array called $Orders. The $Orders array contains order numbers and is later used to query a different table. Ths code works almost great. But there is a problem, if the first checkbox, say PED1 field is not checked, and some of the other checkboxes are (say PED2, PED4), the $Orders array ends being empty. So, say that the form has 5 orders and the user selects orders 2, 4 and 5 and submit it. It does not work. But if he selects 1,2, 4 and 5 it works. It works only if the first checkbox is checked too. What I wonder is why this code does not work if PED1 checkbox is not checked. What if the user only wants other stuff but the first order PED1? Could you help me on this? Here's the code: This is a function that searches for variables called PED1, PED2, PED3 that are checkboxes on a submited form and have the order numbers. When this checkbox is checked, the ordernumber is saved on an Array $Orders that is later used to build a SQL statement. function SearchOrders() { global $Orders; global $HTTP_POST_VARS; $index = count($HTTP_POST_VARS); for($i=1; $i = $index; $i++) { if (isset($HTTP_POST_VARS[PED$i])) $Orders[] = $HTTP_POST_VARS[PED$i]; } $index = count($Orders); return $index; } This is a function that retrieves the array values that are order numbers from the array $Orders and assembles a SQL statement $query. This will later retrieve data from a MySQL table; function MontarOrdRel() { global $Orders; $query = SELECT * FROM tbl_Ord ; if (count($Orders) 0) $query .= WHERE ; for($index=0; $index count($Orders); $index++) { if ($index (count($Orders)-1)) { $query .=(NumPedido = '.$Orders[$index].') OR ; } else { $query .=(NumPedido = '.$Orders[$index].') ; } } // for loop $query .= ORDER BY NumOrd; Then $query is used to query a table. Thank you for your help, Carlos Fernando Scheidecker Antunes. Linux User #207984 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Multiple Threads?
I think what I'm going to end up doing, is using a perl CGI script to do this part. I /know/ perl can do it easily, and I won't have to hack together my own threading code. Thanks for the suggestions though. Matthew Walker Senior Software Engineer ePliant Marketing -Original Message- From: Richard Archer [mailto:[EMAIL PROTECTED]] Sent: Sunday, April 14, 2002 6:41 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Multiple Threads? At 9:25 PM -0600 13/4/02, Matthew Walker wrote: I don't remember the name of the module offhand, but once upon a time, I used a perl module that would fork multiple threads so that you could execute several web queries at the same time. This saved a lot of time, if, for instance, you had to get information from UPS, FedEx, and the USPS about shipping rates to display on a page. If you had to query them one at a time, the delay would be unacceptable. However, with that perl module, you could query them all at the same time, making it much faster. You could system() or shell_exec() an external program/script which forked off 3 children to perform the queries. You would then need to parse the script output for the data you need. system() would require you to capture the script output via output buffering. If you want to use a CGI version of PHP as the external program the functions described at http://www.php.net/manual/en/ref.pcntl.php are what you need. This is a very neat idea. I hope I remember this when I need it :) ...R. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.345 / Virus Database: 193 - Release Date: 4/9/2002 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Search Results, Per Page, Total Results!
Hi, I have a mySQL table on which i'm performing a search.. something like this : $sql_text = (SELECT * FROM searchtb where vCategory='$q' || vSubCategory='$q'); Now i want the Search Results to appear per page.. that is, maybe 15 Records per page should appear.. with something like this on top to navigate through search results : Page : [] 1|2|3|4|5 [] And i would also like to display total results found on results page. Lastly, suppose i have a column vProName in my mySQL Database, which contains a record like this : Millenium basket ball Now if someone searches for basket or ball .. i want this record to show up in search results. How can i make that possible? Can anyone guide me towards this.. Thanks, T. Edison Jr. = Rahul S. Johari (Director) ** Abraxas Technologies Inc. Homepage : http://www.abraxastech.com Email : [EMAIL PROTECTED] Tel : 91-4546512/4522124 *** __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] How can I execute a Command - rsh
I have installed a php server into a w2000 machine, and i must create a user into a service of a sun machine, using a comand like $ executable param1 param2 where param1, param2,... are forms' entries (W2000 IIS form). Can I do a rsh (or a telnet) sesion with php? How... tnkx -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] graphing packages
At 14.04.2002 19:14, you wrote: hey ppl, I need to create some fairly complex graphs dynamically, and I need to be able to specify line, bar, or pie charts. Are there any PHP packages that someone could point me to that would fill my needs. Thanks Have a look at : http://www.phpclasses.org/ and look for graphics. Also http://www.vhconsultants.com/ offer a real good package for your problem. Look for the older library, which is free for personal use, and don´t require a Zend optimizer. Oliver -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Php Config OCX missing in IIS Win2k
At 14.04.2002 22:23, you wrote: When I install php after installing the IIS under win2k Wrong list, you should ask the windowsPHP list ! The setup said Due to missing OCX control , the automatic configuration can not be done. ...-_- how can I fix this problem? I tried google, here´s the result Win32 API OCX Control 1.0 - Downloads - CNET.com - [ Diese Seite übersetzen ] ... In Software Development. ... Win32 API OCX Control 1.0 Download Now Free download 20K More download links, ... download.cnet.com/downloads/0-14482-100-8497698.html - 18k I dont have this problem before, but after formatting my hard drive and reinstall win2k Why didn´t you install an OS ? this appear. plz help! (Dont tell me to config myself, I tried so many time and spend too many hrs...but failed!) I think the manual is fairly good, especially in installing and configuring. There are also some other good explanations, try g*gle. __ ¦èªù³½ SeeMon Simonk ICQ#: 25943733 Current ICQ status: + More ways to contact me i See more about me: __ HTH Oliver -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Newbie Question
I've got a small pb i'm looking to send parameters from a php window to another. I'll try to explain : On the browser i have a page in which i select the first button which has a link in the form of products.php?tosend = 1 but in the second pagein where I try to trap the value of tosend to include a file, i don't get anything. If somebody could help me TYA Hubert DAUL Lyon - France -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Internet Explorer - BACK Button - Passwords?
At 14.04.2002 16:56, you wrote: Don't know if anyone can help me with this one: It's not directly a PHP question -- but maybe someone knows the fix? I have a form, when the user presses the submit button, I pass the form vars to my PHP checkform.php script -- which checks all the fields to make sure the user entered the correct values -- if the user missed something, then they are passed to my error page, which lists out the fields they need fix -- ideally, i would like them to press their browsers BACK button to return to the form, instead of reloading all their session data back into the form with a submit button on the error page -- too much data. So, in Netscape, when a user presses their BACK button all the fields are filled in just as they were filled in ... including the password field. However, in Internet Explorer, when the user presses their BACK button, all fields are good EXCEPT the password fields, which are bank ... so the user is forced to reenter their password info -- kinda annoying. Is there a HEADER or something or an IE fix anyone knows of that will force IE not to delete the password info in this manner? Maybe you should not rely on the browser, save the vars you got in a db or file. If there´s any mistake, send the form again with the data from db/file. (Wow IE has some security function that makes sense ;-) ) HTH Oliver -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] placing data outside the server root
Hi there, is it possible to place data like images outside the server root, and if so does php still get access to them for displaying? thanx, Andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] evaluate my mailing list attempt?
Well, constructed from the help i received from some of you, this is the end result of my attempts to be able to send email to everyone listed in a file and including their names in the email. i would appreciate any feedback or suggestions for simplification, etc. ?$doc=emaillist.dat;$fp=fopen($doc,r); $contents = fread ($fp, filesize ($doc));fclose($fp);//read file contents into variable $list=explode(\n,$contents); //explode each dataset into array $size=count($list);//count number of array items $size=$size-1;//subtract one for looping process $counter=0;//set counter while($counter$size){ //do until no more array items $list2=explode(#,$list[$counter]); //explode each dataset into two separate arrays (name/email) $to=$list2[1];//set to to email address $subject=Newsletter; $msg=Hello $list2[0], bla bla bla; //include name in message mail($to,$subject,$msg); //individual mail during loop $counter++; //increment } ? i know several of you have expressed concerns about overloading email servers, but since i have less than 20 people on the list, i'm sure it can handle it. __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Search Results, Per Page, Total Results...
Hi, I'm working on a search program that searches on a mySQL DB and gives back results.. something like this : $sql_text = (SELECT * FROM searchtb where vCategory='$q' || vSubCategory='$q'); What i want is that the results should be displayed PageWise.. that is, maybe 15 results per page. Something like this : Page : [] 1|2|3|4|5 [] And also i would like to display the Total Results on the resulst page. Secondly, i have a table with a column vProName, which let's say, contain Basket Ball Game. Now what i want is that if someone searches for Game or Ball, even then this record should appear. Could someone guide me for the same Thanks, T. Edison Jr. = Rahul S. Johari (Director) ** Abraxas Technologies Inc. Homepage : http://www.abraxastech.com Email : [EMAIL PROTECTED] Tel : 91-4546512/4522124 *** __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Got an error reading communication packets
I noticed some of my websites written in php with mysql are freezing looked around the logfiles: MYSQL ERROR LOG 020413 14:38:59 Aborted connection 1 to db: 'riderx' user: 'riderx' host: `localhost' (Got an error reading communication packets) APACHE ERROR LOG: [Sun Apr 14 22:23:32 2002] [notice] child pid 29360 exit signal Segmentation fault (11) Cobalt Raq4i Apache version 1.3.20 PHP 4.1.2 MySQL 3.23.37 Where is the problem ?? Is the apache, php or mysql settings are misconfigured?? Any idea what would be the best way to fix it?? Best regards, Andras Kende -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Session problem
I get this errormessage when trying to make my logon work: Warning: Cannot send session cache limiter - headers already sent (output started at /path/to/my/little/session.inc:9) in /path/to/my/little/session.inc on line 10 line 10 contains: session_start(); It does however seem like I am logged in, becase at the bottom of my page, my logout button is appearing. (which it is only supposed to do if session_is_registered(session_id) When clickign the logout button I get this message: Warning: Trying to destroy uninitialized session in /path/to/my/little/session.inc on line 37 Where line 37 says:session_destroy(); Anyone...? Anyone have any links to any really good php session examples? I have read quite a few of them now... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] what do i put in .htaccess to achieve this
Hi, I use wildcard dns to point all requests at the root e.g whatever.mysite.com goes to root etc.however i'll like to redirect these requests to mysite.com/users/sites/whatever so what do i put in the .htacces file bearing in mind that i want requests just for mysite.com to be left alone. thanx adrian
[PHP] rsh or telnet, possible?
I must execute a command in a sun machine, but the web server is IIS (into a W2000 machine). The parameters are the form's fields. Is it possible (better rsh, telnet is valid)? tankx -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] graphing packages
Christian Calloway wrote: hey ppl, I need to create some fairly complex graphs dynamically, and I need to be able to specify line, bar, or pie charts. Are there any PHP packages that someone could point me to that would fill my needs. Thanks Maybe this helps a little: http://freshmeat.net/projects/phpgraphs/ -- Pavel a.k.a. Papi -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Optimizing Indexes and such in MySQL
I'm interested to know how people keep their MySQL tables up-to-date on a regular basis. what is the methodology used to keep up indexes up to date and tables optimized etc... thanks berber
[PHP] newbie question: templates with frames
Hello to all. Please help me in this problem of mine. I have an html template with a frame. I'm using phplib's templating functions to replace values in the templates. How do i also replace values both in the main template (frleft.htm) and in the html page contained in the frame? My code looks like the following: ?php include(prep1.php); $tpl = new NCC_Template(.,keep); $tpl-set_var(test, nyahahaha); $tpl-set_file(array(base = frleft.htm)); $tpl-parse(DefaultPage, base); $tpl-finish(DefaultPage); $tpl-p(DefaultPage); ? - Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax
[PHP] Re: Empty delimiter error - ??
this means in your case, that $email is an empty string Rich Pinder [EMAIL PROTECTED] schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I'm totally unfamiliar with php, and making some slight modificiations to Chris Heilmann's nice v 1.1 Newsleterscript. What exactly is meant by an empty delimiter? This code works just fine, but I get the following error: Warning: Empty delimiter in /home/sites/site56/web/trailcrew.php on line 63 # Put the entries into the array lines $lines = explode(%,$content); for ($key=1;$keysizeof($lines);$key++){ # when the email is not in the list, add the old entries if (!stristr($lines[$key], $email)) { offending line - line 63 $out .= %.$lines[$key]; } # when it's already in the list, set found else { $found=1; } } Thanks Rich Pinder -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Searching a mySQL DB
I'm working on a search program that searches on a mySQL DB and gives back results. I have a table with a column vProName, which let's say, contains a record Basket Ball Game. Now what i want is that if someone searches for Game or Ball, even then this record should appear. Could someone guide me for the same Thanks, T. Edison Jr. __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] placing data outside the server root
Hi there, is it possible to place data like images outside the server root, and if so does php still get access to them for displaying? thanx, Andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Understanding If conditional statements
if ($sql_result = 0) if you want to compare $sql_result with 0 you have to do it: if ($sql_result == 0) = is an assignment operator, == is a comparision operator Lmlweb [EMAIL PROTECTED] schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I'm trying to get my code to print out a sorry - no results message if there is no match. I've read the If statement in the PHP manual (http://www.php.net/manual/ro/control-structures.php#control-structures.if) and I think my code structure may be wrong.. am I wrong to nest it this way in the following code? If so, where should I be putting the if $sql returns 0 records, then print.. code? while ($row = mysql_fetch_array($sql_result)) { if ($sql_result = 0) { $option_block .= Sorry, your search has resulted in 0 records. Please try again. \n; } else { $advocateID = $row[advocateID]; $esc_fname = $row[FNAME]; $esc_lname = $row[LNAME]; $esc_firm = $row[FIRM]; $esc_city = $row[CITY]; $esc_province = $row[PROVINCE]; $esc_area = $row[AREA]; // strips out special characters before output. $fname = stripslashes($esc_fname); $lname = stripslashes($esc_lname); $firm = stripslashes($esc_firm); $city = stripslashes($esc_city); $province = stripslashes($esc_province); $area = stripslashes($esc_area); $option_block .= libName:/b a href=\advocate_details.html?sel_advocateID=$advocateID\$fname $lname/abrbFirm/Organization:/b $firmbrbLocation:/b $city, $provincebrbSpecialty:/b $areabrnbsp;/li\n; } } -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: register_shutdown_function
afaik there is no way to call a class method with register_shutdown_function. simply use a function which calls your constructor function _shutdown() { xmysql::~xmysql(); } register_shutodown_function(_shutdown); Hayden Kirk [EMAIL PROTECTED] schrieb im Newsbeitrag 000501c1e40b$694cab50$62e7adcb@relic">news:000501c1e40b$694cab50$62e7adcb@relic... im trying to make a distructor for a mysql class to kill the connection when the object is destroyed using register_shutdown_function(~xmysql); if i put that in my class will it do that or am i getting confused. ~xmysql is a destructor function i made. Heres the code, will it work how i want it to? class xmysql { var $id; register_shutdown_function(~xmysql); function xmysql() { $id = mysql_connect(localhost,'mystic','cqr73chw'); or die(Could not connect to MYSQL database); } function ~xmysql() { mysql_close($id); } function GetID() { return $id; } } // end xmysql -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] How to sort by 3rd row in an 2d-Array
usort() /uksort()/uasort() look here : http://www.php.net/manual/en/function.uasort.php There is an example in the user notes. Andrey - Original Message - From: SED [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, April 12, 2002 7:25 PM Subject: [PHP] How to sort by 3rd row in an 2d-Array Hi, I'm trying to sort an array like following myArray[1][firstname] = Joe; myArray[1][lastname] = Smith; myArray[1][company] = Bullock; myArray[1][email] = [EMAIL PROTECTED]; myArray[2][firstname] = Jim; myArray[2][lastname] = Cords; myArray[2][company] = Jamen; myArray[2][email] = [EMAIL PROTECTED]; etc... by the company name. How can I do it? I found the solution on php.net (http://www.php.net/manual/en/function.array-multisort.php) but it sorts only the first row: foreach ($myArray as $val) { $sortarray[] = $val['nafn']; echo $val['stadur']; } array_multisort($myArray, $sortarray); Thanks in advance! SED -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: DATES in DIFFERENT LANGUAGES
You would have a look to setlocale and strftime. Example, to have a French date : setlocale (LC_TIME, fr); echo strftime(%e %B); // gives 15 avril Regards, Philippe Declan Kenny [EMAIL PROTECTED] a écrit dans le message news: [EMAIL PROTECTED] Hi all, Is it possible to get dates in different languages i.e. date (j F) would usually return, in the case, 13 April can I make it display the date in French for example?? Thanks Declan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] session_is_registered
On Friday, April 12, 2002, at 07:01 PM, Norman Zhang wrote: If I have register_globals=off, how do I pass session variables? I tried session_register(var1). session_is_registered(var1) appears successful, but if I tried to echo the $var1. Nothing shows. How do I pass session variables? Note that you do not need to use session_register() if you are using PHP4.1.x or greater, in fact you should not use session_register() IIRC. The new way to create or load a session variables is like so: ?php $_SESSION['foo'] = 'bar'; ? It's that simple. Note that you don't need to use a string constant ('bar'), you could use another variable to make $_SESSION['foo'] refer to the same thing, as in: ?php $baz = 'bar'; $_SESSION['foo'] = $baz; ? You can access this new session variable in the way you might expect, by using $_SESSION['foo']. Erik Erik Price Web Developer Temp Media Lab, H.H. Brown [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] HELP! Connect or no connect, that's the question...
Dear all, I installed mysql for windows and had to copy some databases (including mysql standard databases), that I have to use for my php-project. I also installed the Apache server 1.3 ... My problem is, that I get a connect with mysql_connect(localhost, $username, $password); only for the first time after installing an copying the databases. After reboot and starting mysql as a service with mysqladmin and entering password and user in my login.php, this error occurs: 2003: Can't connect to MySQL server on 'localhost' (10061) I tried telnet localhost 3306 under DOS but connection failed. ( After install, it worked ) I tried other users and passwords, which are in mysql.user - but no connect. I don't have a glimpse of an idea left to do. What do I have to do to get the connect with mysql_connect oder do I have to something with the tables in mysql ? After reboot Mysqladmin shows the tables at least... so I desperately need help :-( -- GMX - Die Kommunikationsplattform im Internet. http://www.gmx.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: PHP MySQL Hosting services
What's the URL of host.. Ahh za. I have seen them.. They also run a free php hosting service.. Yes ok but how much downloads/transfer off server do you get?? ::: Julien Bonastre [The-Spectrum.org CEO] A.K.A. The_RadiX [EMAIL PROTECTED] ABN: 64 235 749 494 Mobile: 0407 122 268 QUT Student #: 04475739 ::: - Original Message - From: Vins [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, April 15, 2002 7:12 AM Subject: [PHP] Re: PHP MySQL Hosting services Hey. I have the best hosting you can get. for only $46 p/m ALL THIS... 400 MB web space Execution of Custom CGI scripts Support for PERL Support for C and C++ Support for SSI Support for GCC Support for GD Support for 5 independent MySQL Databases Own URL in the format Extensive Support Forum 99,9% Uptime 24/7/365 Network Monitoring Power Back-up Generator Daily Back-ups Web Site Control Panel FTP User Login 25 POP3 Accessible Mailbox(es) Unlimited E-mail Aliases Online Mail Administration Tool Online Web Mailbox Advanced E-mail Forwarding E-mail Auto Responder Form to e-mail CGI script (cgiemail and formmail.pl) Access to CGI Counter and Counter Configurations Tool Daily Log Files Graphic Statistics Report Disk Usage Monitor Full range of MIME types Execution of PHP scripts (PHP4) Telnet Access (activated on request) SSH Access (activated on request) Microsoft Frontpage 2000 Extensions (activated on request) 5 Databases with MySQL CGI Shopping Cart Custom CGI Support for SSI Perl C, C++ GCC -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Writing Cross DB application
Hello ! I'm planning to write a database application for MySQL, and then port it to PostrgeSQL. Is there any library or class that could help me to write/maintain just one source code for both MySQL and PostgreSQL (on WIN and UNIX)? Thanks in advance. ARcadius -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] XHTML tag attribute quoting (Was Re: Forms in PHP)
On Friday, April 12, 2002, at 07:41 PM, Andrew Chase wrote: Are single quotes valid around tag attributes in XHTML? I skimmed over the W3C XHTML 1.0 spec before posting the previous message and got the impression all attributes had to be double quoted. It would be great if single quotes were valid, since I've fallen into the habit of using them for the same exact reason this thread got started... easier to read and faster to type than \ :) You are correct, single quotes are valid around tag attributes and thus may contain doublequotes (and vice versa). To the best of my knowledge, the following is fine XML/XHTML: select class='uppercontent' multiple=multiple name=beefcake ... /select Erik Erik Price Web Developer Temp Media Lab, H.H. Brown [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Australian *nix Hosts?
Hi yes I have already read the posts about the hosting questions But as I am in Australia I'd like to know if anyone here has had any dealings with a good Australian host and any recommendations.. Thanks a heap.. P.S. I see what spec's US and EU guys have on the sites and from the months I have hunted around AUS I found that it's pretty exp. just to get like 5gb a month downloads is around AUD$300p/m which is kinda pricey for me.. Thanks again.. ::: Julien Bonastre [The-Spectrum.org CEO] A.K.A. The_RadiX [EMAIL PROTECTED] ABN: 64 235 749 494 Mobile: 0407 122 268 QUT Student #: 04475739 :::
[PHP] Re: phpMyAdmin protection
PhpMyadmin now have somekind of authentication method. From the docs: What's the preferred way of making phpMyAdmin secure against evil access? This depends on your system. If you're running a server which cannot be accessed by other people, it's sufficient to use the directory protection bundled with your webserver (with Apache you can use .htaccess files, for example). If other people have telnet access to your server, you should use phpMyAdmin's http authentication feature. Suggestions: Your config.inc.php3 file should be chmod 660. All your phpMyAdmin files should be chown phpmy.apache, where phpmy is a user whose password is only known to you, and apache is the group under which Apache runs. You should use PHP safe mode, to protect from other users that try to include your config.inc.php3 in their scripts. -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlistclient.asp?wlid=664176742884 Mantas Kriauciunas [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hey PHP General List, Can anybody point me to tutorial or real good explanation site how to keep Http://localhost/phpmyadmin off for other users. I am using it to help me with MySQL database but other peaople can access it. I know there is something with .httacces but i dont know anything about that .httacces. SO please if anybody can point me to some explanation how to secure phpmyadmin or just explain bu them selves. Thank You. :--: Have A Nice Day! Mantas Kriauciunas A.k.A mNTKz Contacts: [EMAIL PROTECTED] Http://mntkz-hata.visiems.lt -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Remote file does not return var?
Hi all, is there any reason why an included remote file does not return a variable? I have constructed a login page, where a user can enter his username and password. After completion of the form, I include a verification file on a remote server, that checks the given username and pass with the database on that remote server. I have set up the line as follows: $person_id = include(http://www.someremoteserver.com/check_login.php?user=$userpass=$pass;) and in the remote file: $query = SELECT * FROM persons WHERE per_username='$user' AND per_password='$pass'; $result = mysql_query($query); if (mysql_num_rows($result)==1) { $row = mysql_fetch_array($result); $person_id = $row[per_id]; return $person_id; } else { return -99; } The inclusion was succesful, checking username and pass is succesful, but returning the variable fails, so the value of $person_id is always set to 1. Could this be due to some settings on the remote server, that prevent it from passing variables back? -- Imar de Vries - [EMAIL PROTECTED] - ICQ 6972439 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] what do i put in .htaccesss to achieve this
Hi, I use wildcard dns to point all requests at the root e.g whatever.mysite.com goes to root etc.however i'll like to redirect these requests to mysite.com/users/sites/whatever so what do i put in the .htacces file bearing in mind that i want requests just for mysite.com to be left alone. thanx adrian
RE: [PHP] phpMyAdmin protection
.htaccess ;-) http://httpd.apache.org/docs-2.0/configuring.html#htaccess -B -Original Message- From: Mantas Kriauciunas [mailto:[EMAIL PROTECTED]] Sent: Monday, April 15, 2002 12:35 AM To: PHP General List Subject: [PHP] phpMyAdmin protection Hey PHP General List, Can anybody point me to tutorial or real good explanation site how to keep Http://localhost/phpmyadmin off for other users. I am using it to help me with MySQL database but other peaople can access it. I know there is something with .httacces but i dont know anything about that .httacces. SO please if anybody can point me to some explanation how to secure phpmyadmin or just explain bu them selves. Thank You. :--: Have A Nice Day! Mantas Kriauciunas A.k.A mNTKz Contacts: [EMAIL PROTECTED] Http://mntkz-hata.visiems.lt -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] launching an exe
Hi everybody, Is there a php function I should use to launch an executable program from a users hard drive instead of just creating a link to it?? Thanks alot, Steve. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: placing data outside the server root
Yes, if the user you are, and are trying to access the dir/files, also have access to them. -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlistclient.asp?wlid=664176742884 Andy [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hi there, is it possible to place data like images outside the server root, and if so does php still get access to them for displaying? thanx, Andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Re: Need row number from database select
Keep track of it outside of the function in a global variable. -Original Message- From: SP [mailto:[EMAIL PROTECTED]] Sent: Sunday, April 14, 2002 8:28 PM To: David Robley; [EMAIL PROTECTED] Subject: RE: [PHP] Re: Need row number from database select I see what you are trying to do David but that was what I tried first but it doesn't work because the function calls itself depending if it's not a parent so the alternating colors become all messed up depending on the structure of my folders. That's why I was hoping to get the number for each of the result returned so I could change the color depending if it was odd or even. Any other suggestions? -Original Message- From: David Robley [mailto:[EMAIL PROTECTED]] Sent: April 14, 2002 6:50 PM To: [EMAIL PROTECTED] Subject: RE: [PHP] Re: Need row number from database select Well, you don't need to know what row number is. Something like: function build_folder_tree($output, $parent=1, $indent=) { $color = red; // Set var to first option $qid = mysql_query(SELECT id, name FROM folders WHERE parent_id = $parent); while ($cat = mysql_fetch_object($qid)) { $output .= $cat-name + $indent; // here is where I want to assign diff. colors $color == red ? $color = blue: $color = red; // Cycle color for each iteration if ($cat-id != $parent) build_folder_tree($output, $cat-id, $indent.nbsp;nbsp;); } } -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] graphing packages
hi you could try http://www.aditus.nu/jpgraph/ which looks awesome, but i'm not sure about the license, so please check it... Sebastian -Original Message- From: Christian Calloway [mailto:[EMAIL PROTECTED]] Sent: Monday, April 15, 2002 1:15 AM To: [EMAIL PROTECTED] Subject: [PHP] graphing packages hey ppl, I need to create some fairly complex graphs dynamically, and I need to be able to specify line, bar, or pie charts. Are there any PHP packages that someone could point me to that would fill my needs. Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] accessing raw post data
I'm trying to access data sent to PHP script via POST. But I can't seem to find any documentation on how to do this. Only $HTTP_POST_VARS, but that's not what I want. Anyone know how? Thanks Stuart Schoneveld www.xs4all.nl/~stuartmx -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] newbie running an exe
Hi everyone, My appologies if this is a repost, it's a monday morning. I wan't to know if there is a function in php that I can use to launch an mdb or exe from the users hard drive, I would like to avoid a temp copy being created in windows/iexplorer temp dir because I am getting 2 copies opening when I launch an app from an href. Thanks alot, Steve Junior Software Engineer CompexWaterloo. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] phpMyAdmin protection
Actually the latest releases of phpMyAdmin come with options for password protecting the programs... it's really nice... they're doing htaccess without the .htaccess file (), plus three other forms of verification. Well worth checking out. There's a few lines in the config.inc.php file, and I guess a few words in the documentation about it. Failing that, you should do a search on google for .htaccess, to figure out how to do it the old way. Justin French Creative Director http://Indent.com.au on 15/04/02 2:34 PM, Mantas Kriauciunas ([EMAIL PROTECTED]) wrote: Hey PHP General List, Can anybody point me to tutorial or real good explanation site how to keep Http://localhost/phpmyadmin off for other users. I am using it to help me with MySQL database but other peaople can access it. I know there is something with .httacces but i dont know anything about that .httacces. SO please if anybody can point me to some explanation how to secure phpmyadmin or just explain bu them selves. Thank You. :--: Have A Nice Day! Mantas Kriauciunas A.k.A mNTKz Contacts: [EMAIL PROTECTED] Http://mntkz-hata.visiems.lt -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] What date/time was it 7 hours ago?
What date/time was it 7 hours ago? I'm just trying to make a log using mysql/php This log is kinda supposed to show the time, local to the user. So I store datetime on the format -MM-DD HH:MM:SS in a datetime field. Using the php date function to get the date. This will store the time that right then ON THE SERVER. Now, when fetching data from the mysql table, I want to display what the time WAS, LOCALLY (where I'm at, not the server) when the log entry was made. So. How do I make a function that takes in -MM-DD HH:MM:SS and spits out the -MM-DD HH:MM:SS minus... for instance, 7 hours? What date/time was it 7 hours ago? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: phpMyAdmin protection
you can use the built in auth system. see phpmyadmin manual Mantas Kriauciunas [EMAIL PROTECTED] schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hey PHP General List, Can anybody point me to tutorial or real good explanation site how to keep Http://localhost/phpmyadmin off for other users. I am using it to help me with MySQL database but other peaople can access it. I know there is something with .httacces but i dont know anything about that .httacces. SO please if anybody can point me to some explanation how to secure phpmyadmin or just explain bu them selves. Thank You. :--: Have A Nice Day! Mantas Kriauciunas A.k.A mNTKz Contacts: [EMAIL PROTECTED] Http://mntkz-hata.visiems.lt -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Browsing on Windows
I am querying to see if someone can point in the right direction. What I would like to do is first open a connection to a specific folder (know this) Have it towards the user can click on a button and it will pop up with the local directory and have it so that they can browse their hard drive and click on a file so that they can upload it. Then have then click a button and upload the file! Any pointers on where to start? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Searching a mySQL DB
Check out the MySQL page at http://www.mysql.com/doc/F/u/Fulltext_Search.html. This page talks about doing full-text searches through your data. Then you can implement the queries using PHP scripts to perform the searches.. It works super smooth.. You do have to create an index of any column you want to be able to search but phpMyAdmin will do it for you if you are not familiar with how to do it. Later, Bob Weaver Thomas Edison Jr. [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I'm working on a search program that searches on a mySQL DB and gives back results. I have a table with a column vProName, which let's say, contains a record Basket Ball Game. Now what i want is that if someone searches for Game or Ball, even then this record should appear. Could someone guide me for the same Thanks, T. Edison Jr. __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: what do i put in .htaccess to achieve this
You should be able to find whatever you need here: http://httpd.apache.org/docs-project/ Later, Bob Adrian Murphy [EMAIL PROTECTED] wrote in message 001d01c1e45e$e5d53ae0$02646464@ade">news:001d01c1e45e$e5d53ae0$02646464@ade... Hi, I use wildcard dns to point all requests at the root e.g whatever.mysite.com goes to root etc.however i'll like to redirect these requests to mysite.com/users/sites/whatever so what do i put in the .htacces file bearing in mind that i want requests just for mysite.com to be left alone. thanx adrian -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: evaluate my mailing list attempt?
looks fine but i would change this: $to=$list2[1];//set to to email address $subject=Newsletter; $msg=Hello $list2[0], bla bla bla; //include name in message mail($to,$subject,$msg); //individual mail during to $subject=Newsletter; $msg=Hello $list2[0], bla bla bla; //include name in message mail($list2[1],$subject,$msg); //individual mail during if you do not need $to later. Police Trainee [EMAIL PROTECTED] schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Well, constructed from the help i received from some of you, this is the end result of my attempts to be able to send email to everyone listed in a file and including their names in the email. i would appreciate any feedback or suggestions for simplification, etc. ?$doc=emaillist.dat;$fp=fopen($doc,r); $contents = fread ($fp, filesize ($doc));fclose($fp);//read file contents into variable $list=explode(\n,$contents); //explode each dataset into array $size=count($list);//count number of array items $size=$size-1;//subtract one for looping process $counter=0;//set counter while($counter$size){ //do until no more array items $list2=explode(#,$list[$counter]); //explode each dataset into two separate arrays (name/email) $to=$list2[1];//set to to email address $subject=Newsletter; $msg=Hello $list2[0], bla bla bla; //include name in message mail($to,$subject,$msg); //individual mail during loop $counter++; //increment } ? i know several of you have expressed concerns about overloading email servers, but since i have less than 20 people on the list, i'm sure it can handle it. __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Session problem
Warning: Cannot send session cache limiter - headers already sent (output started at /path/to/my/little/session.inc:9) in /path/to/my/little/session.inc on line 10 this means that there is output before session_start() was called. look at your include files, and make sure that there is no whitespace before the first ?php or after the ? at the end. Torkil Johnsen [EMAIL PROTECTED] schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I get this errormessage when trying to make my logon work: Warning: Cannot send session cache limiter - headers already sent (output started at /path/to/my/little/session.inc:9) in /path/to/my/little/session.inc on line 10 line 10 contains: session_start(); It does however seem like I am logged in, becase at the bottom of my page, my logout button is appearing. (which it is only supposed to do if session_is_registered(session_id) When clickign the logout button I get this message: Warning: Trying to destroy uninitialized session in /path/to/my/little/session.inc on line 37 Where line 37 says:session_destroy(); Anyone...? Anyone have any links to any really good php session examples? I have read quite a few of them now... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: phpMyAdmin protection
http://httpd.apache.org/docs/configuring.html#htaccess http://apache-server.com/tutorials/ATusing-htaccess.html Use this to enable username and password access to phpMyAdmin. Later, Bob Mantas Kriauciunas [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hey PHP General List, Can anybody point me to tutorial or real good explanation site how to keep Http://localhost/phpmyadmin off for other users. I am using it to help me with MySQL database but other peaople can access it. I know there is something with .httacces but i dont know anything about that .httacces. SO please if anybody can point me to some explanation how to secure phpmyadmin or just explain bu them selves. Thank You. :--: Have A Nice Day! Mantas Kriauciunas A.k.A mNTKz Contacts: [EMAIL PROTECTED] Http://mntkz-hata.visiems.lt -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] first time user
That´s not the way to make friends, I think nobody will read your attachments, because it´s not a php-script and this is a PHP-LIST also I had a quick -look on it and found this: If you are having difficulty with the menu please read the FAQ at http://www.milonic.co.uk/menu/faq.php before contacting us. As I mentioned earlier, you can do a better menu without javascript, compatible and functional to all browsers using PHP. This also will load faster, (your testlink took 72sec to load in Opera). I think you should start from scratch. What happens If one disables JavaScript/ Java on his/her machine? - Nothing works At 14.04.2002 20:35, you wrote: thank's again , seems i'm too far still a newbie that the hints you gave me give me a headache and don't let me succeed, if you have the spare time, have a look yourself, i have everything attached, an online copy can be seen at www.janusfoundation.org/test/navigations-testpage.htm. the relevant lines for the links are inside the file stars_array.js on line 162 and 163. maybe you could also recommend a good book for me that explains php for dummies (if you know one in german, even better). Look on php.net books or ask google. thanks coo p.s : i have 3 files attached , 2 here and the 3rd in the follow up because the mailserver doesn't take more than 40kb. Because they limit traffic, I wonder that your attachments found the way to the list, as I think they won´t allow it. TA Oliver -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Help on dealing with arrays of HTTP_POST vars
-Original Message- From: Carlos Fernando Scheidecker Antunes [mailto:[EMAIL PROTECTED]] function SearchOrders() { global $Orders; global $HTTP_POST_VARS; $index = count($HTTP_POST_VARS); for($i=1; $i = $index; $i++) { The trouble is here . You should be test for the max Number of possible checkboxes, and not the number checked. If 3,4,5 are checked, then $index is 3, bu thte varaiables will have names like PED$3, PED$4, PEF$5 and your code will stop at 3. if (isset($HTTP_POST_VARS[PED$i])) $Orders[] = $HTTP_POST_VARS[PED$i]; } $index = count($Orders); return $index; Why not name the checkboxes as arrays like: input type=checkbox name=PED[] value=18191 input type=checkbox name=PED[] value=18192 Then in php, PED[0] is the first *checked* value (so it could be the 5th checkbox). Test with is_array to see if anything is check at all. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Writing Cross DB application
PEAR::DB(); Arcadius A. [EMAIL PROTECTED] schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello ! I'm planning to write a database application for MySQL, and then port it to PostrgeSQL. Is there any library or class that could help me to write/maintain just one source code for both MySQL and PostgreSQL (on WIN and UNIX)? Thanks in advance. ARcadius -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Newbie Question
On the browser i have a page in which i select the first button which has a link in the form of products.php?tosend = 1 but in the second pagein where I try to trap the value of tosend to include a file, i don't get anything. I assume you mean that you can see the value in the URL, but when you access $tosend, it has no value. You should be able to get it from $_GET['tosend']. Or if you are using a version of PHP prior to 4.1.0, you can use $HTTP_GET_VARS. The problem may be that you have register_globals turned off. Janet If somebody could help me TYA Hubert DAUL Lyon - France -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Writing Cross DB application
There's Metabase, one said to be the most complete of them all, available at http://www.phpclasses.org/ and PearDB, available at http://pear.php.net. I am using Pear, most because it takes advantage of another shared classes from Pear itself. For example, the Log class from Pear can use Pear's Db class, and a few other things here and there (nice things, btw ;-) -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlistclient.asp?wlid=664176742884 Arcadius A. [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello ! I'm planning to write a database application for MySQL, and then port it to PostrgeSQL. Is there any library or class that could help me to write/maintain just one source code for both MySQL and PostgreSQL (on WIN and UNIX)? Thanks in advance. ARcadius -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PHP Shopping Engine Recommendation
Can anyone recommend a good commercial shopping cart written in php? Robert W. Collins II Webmaster New Orleans Regional Transit Authority Phone : (504) 248-3826 Email : [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Search Results, Per Page, Total Results!
Here you can find a php class to make it work very simply... http://phpclasses.promoxy.com/browse.html/package/366.html - Original Message - From: Thomas Edison Jr. [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, April 15, 2002 9:23 AM Subject: [PHP] Search Results, Per Page, Total Results! Hi, I have a mySQL table on which i'm performing a search.. something like this : $sql_text = (SELECT * FROM searchtb where vCategory='$q' || vSubCategory='$q'); Now i want the Search Results to appear per page.. that is, maybe 15 Records per page should appear.. with something like this on top to navigate through search results : Page : [] 1|2|3|4|5 [] And i would also like to display total results found on results page. Lastly, suppose i have a column vProName in my mySQL Database, which contains a record like this : Millenium basket ball Now if someone searches for basket or ball .. i want this record to show up in search results. How can i make that possible? Can anyone guide me towards this.. Thanks, T. Edison Jr. = Rahul S. Johari (Director) ** Abraxas Technologies Inc. Homepage : http://www.abraxastech.com Email : [EMAIL PROTECTED] Tel : 91-4546512/4522124 *** __ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] phpMyAdmin protection
At 14.04.2002 21:34, you wrote: Hey PHP General List, Can anybody point me to tutorial or real good explanation site how to keep Http://localhost/phpmyadmin off for other users. I am using it to help me with MySQL database but other peaople can access it. I know there is something with .httacces but i dont know anything about that .httacces. SO please if anybody can point me to some explanation how to secure phpmyadmin or just explain bu them selves. Thank You. :--: Have A Nice Day! Mantas Kriauciunas A.k.A mNTKz Contacts: [EMAIL PROTECTED] Http://mntkz-hata.visiems.lt Bongiorno, To get more Informations about apache, you should look at www.apache.org, - .htaccess, htpasswd and httpd.conf as a fast help, insert the following lines to httpd.conf Directory your_path_to_dir Options Indexes FollowSymLinks AllowOverride Limit # Begin of security relevant commands AuthName secretPassword AuthType Basic AuthUserFile your_path_where_the/.htpasswd #is Limit GET require valid-user /Limit # End of security #Order allow,deny #Allow from all /Directory yo have to add Users to the .htpasswd with htpasswd -options and copy it to your_path_where_the/.htpasswd #is HTH Oliver -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Php Config OCX missing in IIS Win2k
All you need to do is install the ocx file in the system32 dir. Its even in one of the readme files for php. you may need to actually register the OCX in the reg. Thank You Daniel Negrón Lotus Notes Administrator / Developer KB Electronics, Inc. 954.346.4900x122 http://www.kbelectronics.com |+ || heinisch@creac| || tion.de | ||| || 04/15/02 02:40| || AM| ||| |+ -| | | | To: [EMAIL PROTECTED] | | cc: | | Subject: Re: [PHP] Php Config OCX missing in IIS Win2k | -| At 14.04.2002 22:23, you wrote: When I install php after installing the IIS under win2k Wrong list, you should ask the windowsPHP list ! The setup said Due to missing OCX control , the automatic configuration can not be done. ...-_- how can I fix this problem? I tried google, here´s the result Win32 API OCX Control 1.0 - Downloads - CNET.com - [ Diese Seite übersetzen ] ... In Software Development. ... Win32 API OCX Control 1.0 Download Now Free download 20K More download links, ... download.cnet.com/downloads/0-14482-100-8497698.html - 18k I dont have this problem before, but after formatting my hard drive and reinstall win2k Why didn´t you install an OS ? this appear. plz help! (Dont tell me to config myself, I tried so many time and spend too many hrs...but failed!) I think the manual is fairly good, especially in installing and configuring. There are also some other good explanations, try g*gle. __ ¦èªù³½ SeeMon Simonk ICQ#: 25943733 Current ICQ status: + More ways to contact me i See more about me: __ HTH Oliver -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Session problem
On Mon, 15 Apr 2002, Torkil Johnsen wrote: I get this errormessage when trying to make my logon work: Warning: Cannot send session cache limiter - headers already sent (output started at /path/to/my/little/session.inc:9) in /path/to/my/little/session.inc on line 10 line 10 contains: session_start(); Put session_start(); at the very top of your script - make sure there is no whitespace at the top as well. Cheers, Nick Winfield. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: What date/time was it 7 hours ago?
Torkil Johnsen wrote: What date/time was it 7 hours ago? I'm just trying to make a log using mysql/php This log is kinda supposed to show the time, local to the user. So I store datetime on the format -MM-DD HH:MM:SS in a datetime field. Using the php date function to get the date. This will store the time that right then ON THE SERVER. Now, when fetching data from the mysql table, I want to display what the time WAS, LOCALLY (where I'm at, not the server) when the log entry was made. So. How do I make a function that takes in -MM-DD HH:MM:SS and spits out the -MM-DD HH:MM:SS minus... for instance, 7 hours? What date/time was it 7 hours ago? function timebefore($time,$hours=7) { $x = strtotime($time) - ($hours * 3600); return date(Y-m-d H:i:s A,$x); } Michael Kimsal http://www.phphelpdesk.com Guaranteed PHP support when you need it 734-480-9961 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Poor results with GD
Not sure if anyone else uses GD much, but I've been experimenting with it and PHP recently and I've found I get large file sizes and very 'aliased' graphics. Can anyone suggest a fix/ alternative? You'll see what I mean if you look at www.msear.com/paintings/ where the images are currently all generated with GD (but not for long, I think!) Cheers, Mick -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: PHP Shopping Engine Recommendation
http://www.oscommerce.com/ -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlistclient.asp?wlid=664176742884 Robert Collins [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Can anyone recommend a good commercial shopping cart written in php? Robert W. Collins II Webmaster New Orleans Regional Transit Authority Phone : (504) 248-3826 Email : [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] first time user
well, i didn't mean to offend anyone, it's just that me as a non-programmer have quite some difficulties, so I appreceate you telling me this and also having had a look at what i sent. thank's for your advice best regards coo [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... That´s not the way to make friends, I think nobody will read your attachments, because it´s not a php-script and this is a PHP-LIST also I had a quick -look on it and found this: If you are having difficulty with the menu please read the FAQ at http://www.milonic.co.uk/menu/faq.php before contacting us. As I mentioned earlier, you can do a better menu without javascript, compatible and functional to all browsers using PHP. This also will load faster, (your testlink took 72sec to load in Opera). I think you should start from scratch. What happens If one disables JavaScript/ Java on his/her machine? - Nothing works At 14.04.2002 20:35, you wrote: thank's again , seems i'm too far still a newbie that the hints you gave me give me a headache and don't let me succeed, if you have the spare time, have a look yourself, i have everything attached, an online copy can be seen at www.janusfoundation.org/test/navigations-testpage.htm. the relevant lines for the links are inside the file stars_array.js on line 162 and 163. maybe you could also recommend a good book for me that explains php for dummies (if you know one in german, even better). Look on php.net books or ask google. thanks coo p.s : i have 3 files attached , 2 here and the 3rd in the follow up because the mailserver doesn't take more than 40kb. Because they limit traffic, I wonder that your attachments found the way to the list, as I think they won´t allow it. TA Oliver -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Session problem
The message means that that your script produced some output before the session_start. You have to use session_start before any output. The message shows where the output was started (line 9 of the given file). Sometimes output is started accidentally by having a blank space before your ?php tag. Janet - Original Message - From: Torkil Johnsen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, April 15, 2002 2:07 AM Subject: [PHP] Session problem I get this errormessage when trying to make my logon work: Warning: Cannot send session cache limiter - headers already sent (output started at /path/to/my/little/session.inc:9) in /path/to/my/little/session.inc on line 10 line 10 contains: session_start(); It does however seem like I am logged in, becase at the bottom of my page, my logout button is appearing. (which it is only supposed to do if session_is_registered(session_id) When clickign the logout button I get this message: Warning: Trying to destroy uninitialized session in /path/to/my/little/session.inc on line 37 Where line 37 says:session_destroy(); Anyone...? Anyone have any links to any really good php session examples? I have read quite a few of them now... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] globals in functions
On Saturday, April 13, 2002, at 01:37 PM, Paul Roberts wrote: Is there a quick way to set all variables as global so that they are avalible to a function, i'm doing an eval inside, so i need all the submitted variables to be avalible, or do i have to decalre them individualy. If you refer to a POST or GET (or COOKIE or SESSION or SERVER) variable as $_POST['variablename'] or $_GET['variablename'], then it will automatically be global. In PHP 4.1.x or later Erik Erik Price Web Developer Temp Media Lab, H.H. Brown [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] placing data outside the server root
Sure, just give it a try! Kirk -Original Message- From: andy [mailto:[EMAIL PROTECTED]] Sent: Monday, April 15, 2002 5:13 AM To: [EMAIL PROTECTED] Subject: [PHP] placing data outside the server root Hi there, is it possible to place data like images outside the server root, and if so does php still get access to them for displaying? thanx, Andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Internet Explorer - BACK Button - Passwords?
On Sunday, April 14, 2002, at 07:56 PM, Jason Caldwell wrote: I have a form, when the user presses the submit button, I pass the form vars to my PHP checkform.php script -- which checks all the fields to make sure the user entered the correct values -- if the user missed something, then they are passed to my error page, which lists out the fields they need fix -- ideally, i would like them to press their browsers BACK button to return to the form, instead of reloading all their session data back into the form with a submit button on the error page -- too much data. So, in Netscape, when a user presses their BACK button all the fields are filled in just as they were filled in ... including the password field. However, in Internet Explorer, when the user presses their BACK button, all fields are good EXCEPT the password fields, which are bank ... so the user is forced to reenter their password info -- kinda annoying. Is there a HEADER or something or an IE fix anyone knows of that will force IE not to delete the password info in this manner? I get around this entire problem by not forcing the user to use their BACK button if they've made a mistake at all. The form itself is the return value of a function, called print_form() or something like that. I have dozens of these functions in my pages, btw. Anyway, one of the cool things about this is that I can re-use this function as many times as I need to create this form. So if the user fails the error-check or the input is invalid, or whatever, I just execute the function again and the form is displayed. How do I get the original values back? Well, each input in HTML has a value attribute. That's the default value of the input, in the case of text inputs then the value will be echoed in the text box, et cetera. In listbox inputs you can use selected=yes so that the user's choice is selected. I just put the user's input as the value of my HTML form inputs. Here's an extremely simple example of such a function: function print_simpleform() { $simple_form = form method=\post\ action= . $_SERVER['PHP_SELF'] . \ input type=\text\ value=\ . htmlentities($_POST['userinput']) . \ / /form\n; return $simple_form; } Of course, you can get far more complex and have functions that do this but use database info as the default values, et cetera. Also, you may need to stripslash() your $_POST data if you have gpc_magic_quotes = on. Erik Erik Price Web Developer Temp Media Lab, H.H. Brown [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] who added the damn slashes?
Hi, The problem: I don't use addslashes($) but somehow that is what happens to my posted data The situation: I'm building a wizard like form that read all posted data (HTTP_POST_VARS, HTTP_GET_VARS etc..) and puts it in an array that is registerd in a session. This gives me the possibility to use back en next in the wizard form. But every time the slashes are added ! What is the solution PHP version 4.0.3pl1 server is running a slash admin interface (so upgrading is a bit difficult) what to do , to avoid those auto addslasshes ??? kind regards Jeroen Olthof -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] newbie: unix/php/mySQL permissions
I'm very new to php mySQL and need some help understanding how I should set up my Unix permissions. I would like to run php code that could delete/create/edit existing files. I've tried to issue the load data infile statement from the command line but mySQL gives me a permissions error. How can I setup unix/apache/php/mySQL to allow for creation/deletion of files, but still be relatively secure against malicious code? Is there a permissions primer out there that could help this Newbie get familiar with how this all works? Thanks! -Bob -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: graphing packages
Try jpGraph www.aditus.nu/jpgraph/ Christian Calloway [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... hey ppl, I need to create some fairly complex graphs dynamically, and I need to be able to specify line, bar, or pie charts. Are there any PHP packages that someone could point me to that would fill my needs. Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] mysql.sock location
Last night I compiled and installed PHP4.1.2 with MySQL support (compiled in Apache 1.3.24). During the configure routine, it indicated that MySQL's socket was found as /tmp/mysql.sock - which is correct. However, upon looking at phpinfo() after everything was installed, PHP indicated that the socket file was /var/lib/mysql/mysql.sock and consequently started complaining that it can't connect to MySQL through that socket. For the first time in years, I had to manually set the socket information in my php.ini file so that it would work. My question is, why the discrepancy? How come PHP's configure command says the socket is /tmp/mysql.sock, yet when it's actually running, phpinfo() says something completely different? I realize that it's a small problem, which is fixed by setting the value in php.ini, still. Something doesn't jive right. -- W | I haven't lost my mind; it's backed up on tape somewhere. + Ashley M. Kirchner mailto:[EMAIL PROTECTED] . 303.442.6410 x130 IT Director / SysAdmin / WebSmith . 800.441.3873 x130 Photo Craft Laboratories, Inc.. 3550 Arapahoe Ave. #6 http://www.pcraft.com . . .. Boulder, CO 80303, U.S.A. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] newbie: unix/php/mySQL permissions
I'm very new to php mySQL and need some help understanding how I should set up my Unix permissions. I would like to run php code that could delete/create/edit existing files. I've tried to issue the load data infile statement from the command line but mySQL gives me a permissions error. How can I setup unix/apache/php/mySQL to allow for creation/deletion of files, but still be relatively secure against malicious code? Is there a permissions primer out there that could help this Newbie get familiar with how this all works? Thanks! -Bob -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] variable question
Hey Guys and Gals, I'm writing this little script that takes two inputs: $name and $welcomemssg from a form and puts them in a text file. Now i only want to extract one of those variables open it with welcome.php, how do i go about this? when i just do fopen and fwrite it prints both variables. any thoughts? thanks, Jule -- Jule Slootbeek [EMAIL PROTECTED] http://blindtheory.cjb.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] What date/time was it 7 hours ago?
You could convert it to a timestamp using strtotime(), subtract 7*60*60, then convert it back to a string with strftime(). -Steve On Monday, April 15, 2002, at 09:50 AM, Torkil Johnsen wrote: What date/time was it 7 hours ago? I'm just trying to make a log using mysql/php This log is kinda supposed to show the time, local to the user. So I store datetime on the format -MM-DD HH:MM:SS in a datetime field. Using the php date function to get the date. This will store the time that right then ON THE SERVER. Now, when fetching data from the mysql table, I want to display what the time WAS, LOCALLY (where I'm at, not the server) when the log entry was made. So. How do I make a function that takes in -MM-DD HH:MM:SS and spits out the -MM-DD HH:MM:SS minus... for instance, 7 hours? What date/time was it 7 hours ago? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Remote file does not return var?
On Monday, April 15, 2002, at 10:05 AM, Imar de Vries wrote: is there any reason why an included remote file does not return a variable? Think of include() as a function that simply imports the data from the included file and inserts it directly into the script that is doing the including. So, any variables that were available in your included file are now included in your script, although they are not returned in the sense that you are hoping for. Erik Erik Price Web Developer Temp Media Lab, H.H. Brown [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] newbie: unix/php/mySQL permissions
I'm very new to php mySQL and need some help understanding how I should set up my Unix permissions. I would like to run php code that could delete/create/edit existing files. I've tried to issue the load data infile statement from the command line but mySQL gives me a permissions error. How can I setup unix/apache/php/mySQL to allow for creation/deletion of files, but still be relatively secure against malicious code? Is there a permissions primer out there that could help this Newbie get familiar with how this all works? Thanks! -Bob -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Empty Delimiter error
Thanks so much Daniel. Indeed, the old line that I modified didnt use a function call. The old line was: if ($lines[$key] != $email){ So, the @ suggestion works just fine: if (!@stristr($lines[$key], $email)) { Seems like a cryptic syntax for an error code of this meaning - and odd that all the PHP sources I searched before posting here came up empty for the terminology. Thanks again Rich Daniel Grace wrote: Rich Pinder [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Let me try again: This line of the script: if (!stristr($lines[$key], $email)) { yields the following error: Warning: Empty delimiter in /home/sites/site56/web. Do you know what causes this error ? Thanks r My guess is that $email is empty (or possibly $lines[$key]). The documentation for stristr says nothing about generating warnings on such an occurance, but it would make sense. If your script can handle $email being empty, simply adjust your level of error-reporting or silence the warning with an @. Otherwise, fix whatever it is that's causing $email to be empty. -- Daniel Grace -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Poor results with GD
They looked ok to me, but I don't know what the orginals looked like. But the problem might be that your JPeg quality is set lower than you would like. You can increase it be setting a parameter in ImageJPEG() or most likly whatever function you are using Andrew - Original Message - From: Sear, Mick [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, April 15, 2002 4:32 PM Subject: [PHP] Poor results with GD Not sure if anyone else uses GD much, but I've been experimenting with it and PHP recently and I've found I get large file sizes and very 'aliased' graphics. Can anyone suggest a fix/ alternative? You'll see what I mean if you look at www.msear.com/paintings/ where the images are currently all generated with GD (but not for long, I think!) Cheers, Mick -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Accessing variables: $_POST and $foo
While prototyping my db-driven website using Apache 1.3.23 + PPHP 4.1.2 + PostgreSQL 7.2 under the rpm distribution of Mandrake 8.2, I used the default register_globals=on setting. As I'm nearing the end of protyping, I decided to switch register_globals=off by ediuting the php.ini file. Unfortunately, by doing so, I lost the connection to PostgreSQL: phpinfo() shows no settings for psql. Since it's a pre-packaged rpm, I've no way to change the default setting aside from editing the php.ini which then breaks PostgreSQL connection. I could source the whole mess, but since I'm nearing the end of protyping it seems like a waste of time. I've re-written most of my code to $_SESSION and $_POST to pick up the variables from the various pages. However, in order to test everything I've had to re-load PHP with globals again set to on. Now for the question: I would like to know whether the coding for the variables that I'm using now will work with $_SESSION and $_POST. For some reason, the only way to pick up the variables from a posted page is to use at the beginning of the page (after the initial ?php session_start(); ob_start(); ?) $sfname = $_POST['sfname']; Now, in all the checking code that follows (to check for empty strings, html code, javascript commands, and bad words) I've reverted to: //snippet of code (h5 is formatting for CSS stylesheet) if ($sfname == ) die (h5blah, blah blah/h5); This works with globals=on, and while I had it working (without a functional database connection) with $_POST and but not with $_SESSION (??). My question: will this work in real-time once I get connected again to the db? It's so frustrating having changed all the code to find that I really didn't have to. Btw: can anyone explain why register_globals=on is such a bad thing? I've read the security info, and they never really explained it. Sorry for the long post. I would greatly appreciate any assistance on this. Tia, Andre -- Please pray the Holy Rosary to end the holocaust of abortion. Remember in your prayers the Holy Souls in Purgatory. May God bless you abundantly in His love! For a free Cenacle Scriptural Rosary Booklet: http://www.webhart.net/csrb/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: placing data outside the server root
Well, you couldn't put an image outside the document root, and use a normal HTML tag (img src=image.gif) obviously, because the browser wouldn't be able to read it... but you could do img src=fetchimage.php?image=image.gif and the program fetchimage could go to a directory (not in your document root) and look for the image image.gif. If it found it, it could pass back the appropriate Content-Type header (in this case image/gif), and then open the image as a file, and start spiting back the binary of the image to the browser. something like this: $file = /path/to/images/$image; $imagep = @fopen($file,r); if ($imagep) header(Content-type: image/gif); while(!feof($imagep)) $buffer = fread($imagep,4096); echo $buffer; } fclose($imagep); } Something like that. Good luck, Mike [EMAIL PROTECTED] Hi there, is it possible to place data like images outside the server root, and if so does php still get access to them for displaying? thanx, Andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] register_shutdown_function
On Sunday, April 14, 2002, at 07:23 PM, Hayden Kirk wrote: im trying to make a distructor for a mysql class to kill the connection when the object is destroyed using register_shutdown_function(~xmysql); if i put that in my class will it do that or am i getting confused. ~xmysql is a destructor function i made. Heres the code, will it work how i want it to? I did not think that PHP had support for destructor methods. You could call your xmysql method manually if you like but you can't have it called automatically if your object is unset(). This is according to: http://www.php.net/manual/en/language.oop.constructor.php , down at the bottom just before the annotations. Erik Erik Price Web Developer Temp Media Lab, H.H. Brown [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] who added the damn slashes?
I believe your php.ini file has the magic_quotes set to On. If you switch this to Off it will no long add the quotes for you. Sincerely, Robert T. Covell President / Owner Rolet Internet Services, LLC Web: www.rolet.com Email: [EMAIL PROTECTED] Phone: 816.471.1095 Fax: 816.471.3447 24x7: 816.210.7145 -Original Message- From: Jeroen Olthof [mailto:[EMAIL PROTECTED]] Sent: Monday, April 15, 2002 5:42 AM To: [EMAIL PROTECTED] Subject: [PHP] who added the damn slashes? Hi, The problem: I don't use addslashes($) but somehow that is what happens to my posted data The situation: I'm building a wizard like form that read all posted data (HTTP_POST_VARS, HTTP_GET_VARS etc..) and puts it in an array that is registerd in a session. This gives me the possibility to use back en next in the wizard form. But every time the slashes are added ! What is the solution PHP version 4.0.3pl1 server is running a slash admin interface (so upgrading is a bit difficult) what to do , to avoid those auto addslasshes ??? kind regards Jeroen Olthof -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Writing Cross DB application
ADOdb is probably your best bet for this. http://php.weblogs.com/ADODB Mike... Arcadius A. wrote: Hello ! I'm planning to write a database application for MySQL, and then port it to PostrgeSQL. Is there any library or class that could help me to write/maintain just one source code for both MySQL and PostgreSQL (on WIN and UNIX)? Thanks in advance. ARcadius -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Detecting language
Hi I have an application that works with two languages. I'm trying to write a function that will tell me if a string contains only English or also chars from the other language. It's enough that there is one char of a different language to make the function return a true value. I guess I'm not inventing the wheel here... Sincerely berber Visit http://www.weberdev.com Today!!! To see where PHP might take you tomorrow. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php