#php
14 October 2007
Total 27 pages. You are browsing page 1/27.
First :: Prev :: [1] [2] [3] [4] [5] [...] :: Next :: Last
--- Log opened Sun Oct 14 00:00:02 2007
--- Day changed Sun Oct 14 2007
00:00 <****> if i echo $_POST['vp'] i get a number from the previous form
00:00 <****> so they both exists
00:00 <****>msg_page_navbar.
00:00 <****> AlReece45: and this is not what i need, as you can expect ;)
00:00 <****>type . '_navbar';
00:01 <****> how come when i use backslashes in: define('LOG_PATH', 'C:\foo\logs'); it makes my syntax highlighter go crazy, but not if i use forward slashes. is it php or my editor's fault?
00:01 <****> what does an @ symbol in front of a function mean
00:01 <****> suppress warning messages
00:01 <****> Exstatica: try doing var_dump($_POST[$field]) where you're using it
00:01 <****> graywhite: your editor.
00:02 <****> stupid dreamweaver
00:02 <****> claudio`: when you try using you're $test and doing $$test, it tries to find a variable named $test, it doesn't see that the first part is an object and the second part is a variable on that object.
00:03 <****> too (just to know)?
00:04 <****> claudio`: you could try using eval()... but using it is not a good practice, it doesn't benefit from optimizers/accelerators/caches, runs slower than the example before, runs slow period... and might be a bad security option.
00:04 <****> is there a way at the end of a script to send someone to a page instead of using include 'csm_view.php'; cause if its refreshed in browser runs the whole script again and i get double entrys
00:05 <****> AlReece45: then your previous solution is definitively what i was looking for.
00:05 <****> AlReece45: THX for helps.
00:05 <****> i want them to get sent to csm_view.php
00:05 <****> AlReece45: vardump says null
00:05 <****> instead of including it
00:05 <****> claudio`: okay
00:06 <****> i have: define('LOG_PATH', 'C:/logs/'); Why does this line give me a syntax error: function log($file = LOG_PATH . 'my.log')
00:06 <****> or am i just crazy ?
00:06 <****> Exstatica: $_POST[$field] definitely isn't set. You might want to do var_dump($field); at the same place
00:07 <****> graywhite: you can't concatenate in the function declaration.
00:07 <****> oh man that's gay
00:07 <****> AlReece45: echo $field; gives me a value of VP, echo $_POST['VP']; gives me a value of 20
00:07 <****> first i cant use a function that returns a string in a function declaration, now i can't concat either :(
00:08 <****> graywhite: you can set it inside function
00:08 <****> true
00:08 <****> i'll just do that
00:08 <****> header() did the trick is there a more proper way todo it ?
00:08 <****> header() is the proper way
00:09 <****> function log($file = null) { if($file==null) $file == LOG_PATH... }
00:09 <****> exstatica: is if 'vp' or 'VP'?
00:09 <****> hmm
00:10 <****> Exstatica: You're saying that like that's something bad.
00:10 <****> i need mroe like: function log($file = 'my.log') { $file = LOG_PATH . $file; }
00:10 <****> AlReece45: its VP
00:10 <****> all caps
00:10 <****> Wolfpaws: i'm trying to do $_POST[$field]
00:10 <****> but its coming out blank
00:10 <****> what's better practice to use, a global constant or a function that returns a string?
00:12 <****> exstatica: I understand that, its just that the computer normally doesn't make consistant mistakes like that. var_dump is saying that $_POST[$field] is not set, so var_dump($field) might show if something wrong, like maybe if there's an extra space in the string or something.
00:12 <****> Exstatica: it is working for everyone except you
00:13 <****> its like doing $b = 1 + 1; $a = 1; $c = $a + 1; $d = $a + $a; and somehow getting different values for $b, $c, and $d
00:13 <****> string(2) "VP" }
00:14 <****> :))
00:14 <****> is p { ul { style; } } valid?
00:14 <****> no
00:14 <****> hm
00:14 <****> [domon]: I think this is the wrong channel, and I don't believe it is
00:14 <****> [domon]: #css
00:16 <****> Exstatica: what php version are you using?
00:16 <****> 5
00:16 <****> Exstatica: echo $field
00:17 <****> there's an article at devzone.zend.com about Blueprint of php applications,... is there a part 3 coming ?
00:17 <****> Wolfpaws: VP
00:17 <****> string(2) "VP" }
00:17 <****> but echo $field shows VP
00:18 <****> Exstatica: Please pastebin the code
00:18 <****> Exstatica: I believe they have __toString method... that converts it that way.
00:18 <****> Exstatica: try $_POST[(string)$field];
00:19 <****> http://www.pastebin.ca/735750
00:20 <****> AlReece45: that did it
00:20 <****> thank you
00:20 <****> it was driving me crazy
00:21 <****> Exstatica: you're welcome
00:22 <****> nite
00:22 <****> is there some utility to browse through php code (like ctags for C) ?
00:23 <****> how to browse?
00:23 <****> kazim59: a quick google with "ctags for php" brought up http://www.linuxdocs.org/HOWTOs/PHP-HOWTO-10.html which shows a ptags program... you'd have to compile it yourself.
00:24 <****> kazim59: or are you on windows?
00:24 <****> anyone have experience with scriptaculous sortable lists, in particular when using many lists on a page
00:24 <****> [[fields]]: not php
00:24 <****> oh shit, wrong window, sorry
00:24 <****> AlReece45: I am a God fearing person.
00:24 <****> AlReece45: thanks for ptags
00:25 <****> kazim59: that is the first time I've heard of it though, but the links below it promote it.
00:26 <****> kazim59: if you need more to look at http://www.google.com/search?q=ctags+for+php
00:27 <****> Is it possible to offer file_X.txt downloadable as Anothername_file.txt?
00:27 <****> With some php magic offcourse.
00:28 <****> but link must to remain file_x.txt ?
00:28 <****> better to use some mod_rewrite magic :)
00:28 <****> Hm.
00:29 <****> Was asking earlier if it was possible to offer a download which is generated on the page.
00:29 <****> I'm asking weird questions aint i :P
00:30 <****> yes, it's definately possible
00:32 <****> Is there anyone who is using ATK framework?
00:33 <****> just DJANGO
00:39 <****>logged_in) if logged_in is a bool ?
00:39 <****> ! ?
00:39 <****> lol
00:39 <****> :P
00:39 <****>logged_in)
00:40 <****> I've seen professional web applications with field values containing a php array... this violates 1NF... is that okay to have such a design?
00:40 <****> so none is working with atk framework?
00:41 <****> kazim59: ok for what?
Total 27 pages. You are browsing page 1/27.
First :: Prev :: [1] [2] [3] [4] [5] [...] :: Next :: Last
