Home Page   #c  #ruby-lang  #cisco  #mysql  #apache  #javascript  #java  #perl  #php  #openmoko   Wallpapers Girl
Reliable $1 Web Hosting by 3iX

Channels


#php

29 December 2007


Total 28 pages. You are browsing page 1/28.

First :: Prev :: [1] [2] [3] [4] [5] [...] :: Next :: Last

--- Log opened Sat Dec 29 00:00:13 2007
--- Day changed Sat Dec 29 2007
00:00 <****> sorry
00:00 <****> anyways.... i had to stir up the pot
00:00 <****> I gotta leave work now and shut down my comp
00:00 <****> catch you all next week
00:01 <****> can i clean an array from empty records with some php native function?
00:02 <****> No.
00:02 <****> thank you mattmcc
00:04 <****> anyone here use HTML_QuickForm ?
00:04 <****> Char80: Depends on if the values are strings or not
00:05 <****> Char80: You can use a combination of array_filter() and strlen(), for example.
00:05 <****> kuja, it is filled with strings
00:05 <****> $values = array_filter($array, 'strlen');
00:06 <****> This will return an array of strings that do not include the completely empty ones.
00:07 <****> You can also just use $values = array_filter($array); // because the default behavior is that it will not include any values that evaluate to false (and empty strings evaluate to false in PHP)
00:07 <****> I'm storing binary data in MySQL with the data type, file size, etc. When I retrieve that data it seems to be corrupted. Any help?
00:13 <****> anchovy: Using a MySQL client, can you directly query the data into a file and verify that it is indeed a problem with your php script?
00:14 <****> kuja, it works with both methods, thanks for the help
00:14 <****> You're welcome.
00:18 <****> jmccaffrey, no, I am storing a binary string produced from file_get_contents in to a BLOB field in MySQL, some documents are corrupted (pdf, excel) and some are not (doc)
00:18 <****> question: Do static methods get passed in inheritance as instance methods do? if so, inside an inherited method, does self point to the parent class or the extending class?
00:19 <****> So I realized, that on my Ubuntu-Box (6.06 LTS) I'm left with a non-bundled version of the GD Graphics Library.. Do I have to recompile php from source (--with-gd, ...) to get access to the extra functions in the bundled GD version, or is there an easier way to do it?
00:20 <****> jmccaffrey, nvm I fixed it, thanks for your help (I changed the field type to LONGBLOB and it works, my data string must have been too large)
00:20 <****> THX anyway for your help, bbl
00:21 <****> anchovy: IF you're using DB for storing binary data, there is a flaw in your design.
00:22 <****> Wolfpaws, I know you're not supposed to store binary data in MySQL
00:22 <****> carrierBag: you likely have to install php-gd as on other common distributions
00:22 <****> Then why are you doing so?
00:22 <****> Wolfpaws: sometimes it's more convenient to store binary data in a DB rather than use the file system directly.
00:22 <****> well this app I'm doing isn't going to be used often at all and is only going to store around 15-20 rows of data
00:23 <****> "SELECT password FROM users WHERE username='".$_POST["username"]."'"; <-- How would you mysql inject this query? I am using this and am wondering if it can be exploited if mysql_real_escape_string() is not applied.
00:23 <****> Determinist: It's *NEVER* moree conviniet to do so.
00:24 <****> rsc: well, the php5-gd package on ubuntu is not the bundled version. As I understand it, I only get the bundled one if I compile php with --with-gd .. uhm and I'd rather not compile my own one.. well, I eventually have to I guess :|
00:24 <****> hello, how do i convert a link received from a shoutbox text, to html link?
00:24 <****> http://24.81.254.112/seditio.121//index.php
00:24 <****> by using the anchor tag
00:25 <****> huh?
00:25 <****> Wolfpaws: in very specific cases, it can be more convenient. Very specific tho.
00:25 <****> what? do you not know what an anchor is?
00:25 <****> carrierBag, it's not a big deal compiling on ubuntu... it's usually pretty easy...
00:25 <****> Wolfpaws: mind you, i'm not talking about large binary files.
00:25 <****> JWay, do you have magic_quotes enabled on the server?
00:25 <****> yes, but how do i do it?
00:26 <****> I would say my case is specific :P
00:26 <****> Kapace, carefully
00:26 <****> djahandarie: no it is not enabled
00:26 <****> Determinist: I'm working with PHP for 6 years, done most kind of applications. In all that time I've never found a "good reason" to do so.
00:27 <****> The you could send in $_POST["username"] something like: ' OR 1=1
00:27 <****> heh
00:27 <****> krustofski: can you give me an example?
00:27 <****> And it would pull all the passwords.
00:27 <****> the example would be me doing it for you
00:27 <****> Wolfpaws: i haven't either, but i've seen such a design in use and at the time, it seemed like a reasonable solution.
00:27 <****> djahandarie: but is magic quotes not deprecated?
00:27 <****> is a link
00:28 <****> k yes..
00:28 <****> Determinist: Than you had a big flaw in your logic.
00:28 <****> think about what you have to echo and what you have to replace to make a link
00:28 <****> krazytekn0: ok. I'll do it. *touches some wood
00:28 <****> Wolfpaws: well, if it makes you feel better about yourself, sure.
00:28 <****> JWay, it's deprecated in 6, but I'm guessing you're not running 6.
00:28 <****>
00:29 <****> oops forgot the actual link
00:29 <****> Determinist: When was the "need" to do so?
00:29 <****> !tell Kapace about tias
00:29 <****> carrierBag: what will probably happen is first install the build-essential package (I'm almost sure that's still what it's called)
00:29 <****> djahandarie: good guess.. is there some kind of replacement for the magic quotes in 6?
00:29 <****> Wolfpaws: shared hosting, minimal storage space, unlimited database storage... do the math.
00:29 <****> krazytekn0: yes, thanks. I read about that in some guides I've found.
00:30 <****> JWay, it would be filtering all the data manually.
00:30 <****> then you download the stuff you want to compile, take a stroll through the config files to see where/how to set the options you want
00:30 <****> djahandarie, okay then
00:30 <****> With for example addslashes.
00:30 <****> Determinist: That tells me tha you have a sucky host.
00:30 <****> magic_quotes is on by default in 4 and 5 though.
00:30 <****> then ./configure in the directory you untarred to (or unzipped)
00:31 <****> So unless you manually disabled it, it's most likely on.
00:31 <****> then you'll probably see some other stuff you should install, so like apt-get install blahsomelibsyouneed-dev
00:31 <****> Wolfpaws: dude, i said i've seen it done, i didn't say I did it. i'd never pay for a hosting service with those terms, but a friend of mine did and he found whatever solution he could.
00:32 <****> and you just keep doing that till it works!
00:32 <****> krustofski: so i have a variable that might contain a link and/or other text (.. its a shoutbox) how do i grab that link out of the garbage?
00:32 <****> carefully
00:32 * Kapace sighs
00:32 <****> hi all.
00:32 <****> yes i know i have to do it carefully!
00:32 <****> hi all.
00:32 <****> djahandarie, alright I was just testing at a free php/mysql hosting site and they had it disabled.. thanks for the info
00:32 <****> i'm looking for a PHP-based ticket sales management program, does anyone know where i'd find one?
00:32 <****> krazytekn0: yes, that's the plan. My last concerne is: should I uninstall/remove php first with synaptic or won't I get a messed up system (packages wise...)?
00:34 <****> carrierBag: I don't think it will actually mess up your system, but I'd ask that question to #linux to make sure
00:34 <****> or #ubuntu
00:34 <****> ok thanks
00:35 <****> Wolfpaws, i could imagine binary data requiring a storage facility with acid properties
00:35 <****> krustofski: should i use regexs?
00:35 <****> you could
00:36 <****> no problem
00:36 <****> what other options do i have?
00:36 <****> MichielH: Um... That's 'filesystem', isn't it?
00:36 <****> Wolfpaws, whats the link to all the string manip functions?


Total 28 pages. You are browsing page 1/28.

First :: Prev :: [1] [2] [3] [4] [5] [...] :: Next :: Last


Tutti i nuovi CAP Italiani. Come ottenere il database completo