| |
| |
| |
|
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
Comments:
<0> bbl <1> gotaq: Welcome. <2> kosh[0]: its the same lgpl and gpl if you want to use the code you have to state somewhere where and who you got it from and put the source code on the net for download <3> thanks for everything <4> You don't have to put the code on the net <5> well, it doesn't have to be on the net for download, it has to be avaliable to the one buying the app, cd, floppy, or what have you <4> You have to just make it available if someone asks for it. <2> gnu told me id have to <2> put it on the net for download that is <3> well the code is shipped to the clients server as part of the software we produce <2> yea or come with the app <3> but we wanted to keep it closed, cause we make our money from it, so we'll just have to engineer out the pear modules <5> kosh[0], then you have to give the customer access to the source <2> kosh[0]: then yea fine to use it just state where and who you got it from in a rem line at the top of the code <3> habbe: yeah <6> kosh[0]: PEAR can be distributed with Closed source apps, no problem, it's all LGPL or BSD based licenses
<3> awormus: ?? thats the opposite of what habbe just said <5> i might be wrong;-) <6> then habbe is wrong :) <3> LGPL states you have to distribute the code if you mix the codebases together? <3> but you are fine to dynamically link against it, but not statically link, right? <6> GPL: You have to distribute ALL code linked to the GPL code <6> LGPL: you don't have to distribute linked code <3> so including an LGPL pear module into your closed source script, surely you are mixing them <2> you can link to the original code i think and not to yours unless yours is under gnu <6> LGPL is best for libraries, so that people can use them in their own code without giving their code back <3> awormus: yeah, thats my interpretation of compiled code, but this is script, where the LGPL pear module is directly included <6> kosh[0]: it's no problem, there are no issues :) <3> BSD is of course fine, LGPL doesnt make sense I dontthink for PHP scripts, since using them directly mixes the codebases <2> kosh[0]: then tell your clients where to find the pare module not your code <3> awormus: I aint sure youre 100% on that, I know a bit about these things too and what you're saying doesnt sound right <2> that would work <6> kosh[0]: I've personally met 80% of core pear developers, they couldn't care less :) <6> what package is it? <2> lol <7> Is there any drawback to defining __autoload() ? <6> Etriaph: you can only do it once <3> awormus: ah, well couldnt care less is different from following the terms of the licence, which as an individual in your bedroom might work, but for a company, would not <3> awormus: we use the pear validate cl***es and the database abstraction cl***es <7> That's fine, but I ran into a really strange problem with PHP and I now have to resort to defining this function. <7> It involves sessions and an object I'm storing. <8> Did you define the cl*** before calling session_start? <6> kosh[0]: go to #pear if you have questions :) <3> ah ok <2> ok can anyone tell me a good secure shopping cart in php please <6> kosh[0]: that would be #pear on efnet :) <7> I have a cl*** that gives me access to the session variable $_SESSION. It's used to perform calculations on some variables at certain times, etc. <7> So I do require_once "Session.php"; require_once "User.php"; $user = Session::get("User"); and I get an error *if* Session.php is required twice with require_once <7> Before the cl*** definition of Session in Session.php, I call session_start(); <2> is the <2> Etriaph: is the session.php asked for in the user.php files aswell <7> illegalc0de: No, but it's required more than once before I call Session::get("User"); <7> Multiple cl***es make use of it, and I call require when a cl*** specifically needs another cl***. <7> This way I can use the cl***es independantly or inside the system. <7> What happens if you require_once "file.php"; twice and that file.php calls session_start(); <2> the think about the link $require_once(); is that it will only let the file be incuded "once" if you want to use it more than once in a 1 file use instead require(); <7> Should it not only require it once? <2> if you use the "once" method then it will give you lost of errors <7> Well, I don't call require_once more than once in a single script. <7> But if I call require_once "Session.php"; and require_once "Authentication.php"; Auth requires Session, would that blow up? <2> but if you use require_once(); in any of the others that are being required for that script then it will be the same as saying it twice <7> But it doesn't blow up elsewhere. <2> say you have 3 files well name them index.php, session.php and auth.php ok <2> .... <7> If I require_once "Document.php"; and require_once "SideBar.php"; it doesn't blow up, and both of them require_once "Session.php"; <7> It's when I try to use an object stored in the session. <7> $user = Session::get("User"); $user->getUserID(); <7> That blows up <7> *shrugs* <7> But if I remove require_once "Session.php"; from a single place (and it's included in more than just that one place), it works. <2> if you require_once("session.php"); require_once("auth.php"); in index.php and also require_once("session.php"); in auth.php then it will give you errors cause the 3 files are becomeing 1 and it is useing them as 1 php file <2> are hang on <7> The script tried to execute a method or access a property of an incomplete object. Please ensure that the cl*** definition "User" of the object you are trying to operate on was loaded _before_ unserialize() gets called or provide a __autoload() function to load the cl*** definition <2> Etriaph: your useing $user Session::get("user"); $user->getUserID(); <7> That's the error I get. <2> tel me if im wrong. your trying to get the users id from a session? <2> tell^
<2> typos lol <7> I'm trying to get the User object from the session. <7> The whole object is stored. <7> Session::set("User", new User()); for all intents and purposes. <9> is it possible to have a checkbox return a value even if not checked? <9> i.e, if its checked, it returns 1, otherwise 0 ? <10> You could code that.. if (!empty($_POST["check_box"]) { $checkbox =0; } <11> I think that might be if (!isset($_POST["check_box"] <11> IIRC checkbox values are only set if checked. <10> They are set... actually it would be <10> if (isset($_POST["check_box"]) && empty($_POST["check_box"]) <12> hi there, I wondering if someone can help me with the ereg() function. I have a string like this "/images/properties/home" and I want to capture the string minus the last part "/home". <12> my current pattern is "^(.*)(/.*?)$" but I keep getting a REG_BADRPT error. anyone got any clues what I'm doing wrong <13> College, you -could- explode, detect last array entry, and then just use that entry <14> hi! <14> any one can tell me how can i replace aba"> or (any char)"> with ""? <12> elkbuntu: I'm not needing the last entry, I need the first part of the string. I was thinking explode, delete last array entry and then implode <12> but not the smartest way <9> danf_1979 and wobbles: thanx, didnt think og that <15> College: dirname('/images/properties/home') == '/images/properties' <9> og = of <13> College, i know, but if all else fails ;) <16> you could use substr and strrpos too <14> can i use "(*)?\">"? <15> You guys are overcomplicating this. <15> dirname() exists for this particular case. <16> kuja: agreed, if it's always / as the delimiter <12> sh*t completely forgot about dirname <12> thanks guys <15> I'm ***uming he's working with directories. <12> yes I am <15> Then you're fine :) <14> College: also chdir() or getcwd <15> alecs: What's that got to do with it? <17> does PHP5 have eval? <17> the eval() function? <15> pakoo: Yes, unfortunately. <17> kuja, eval rocks! <17> :-) <14> *maybe could help <15> !+eval <18> If eval() is the answer, you're almost certainly asking the wrong question. -- Rasmus Lerdorf, BDFL of PHP <19> ok <11> eval is a great way to ***ist you in shooting yourself in the foot <14> :) <8> I've used eval exactly once in all my projects, and that was because I actually wanted the (rarely used) ability to run arbitrary code at run time <19> kuja: how would i instantiate a cl*** of which i only know the name at the time the file is uploaded ? <19> yes, what Dragnslcr said <19> it's the only use i've had for it so far <15> boro_O: $cl*** = 'Foo'; $obj = new $cl***(); <8> It's a constantly-running program, so I use it once in a while for debugging, but that's it <19> kuja: that actually works :) <15> Yes, it does. <19> I never knew <15> Apparently *you* don't have a reason to use eval(). Rasmus Lerdorf was right, wasn't he? <19> thx ! <20> hi <20> is it possible to produce memory leaks with php? <8> Quite easily <20> or: will php free local variables after a function returns? <8> Oh, you don't mean on purpose <20> i have a commandline php script which deals a lot with strings <21> Hi guys, anybody know anything about adding a UUID to mysql records using phpmyadmin...? Is there a native mysql 'uuid' function ...? <8> Yeah, PHP should take care of garbage collection for you <20> this terminates with an out of memory error <15> Dragnslcr: I don't believe it does. <15> PHP will clean it all up at the end of execution. <8> Hm <21> I've asked on #mysql ... but nobody knows anything <15> Dragnslcr: This has been a big problem with PHP not being ideal for persistent CLI/GUI applications, I believe. <22> babo: http://dev.mysql.com/doc/refman/5.0/en/miscellaneous-functions.html <15> Dragnslcr: I do think unset()'ing a variable, or $variable = null; achieves something, not sure. <22> babo: and search for "UUID"
Return to
#php or Go to some related
logs:
apollon suse 10.1 rpm xscreen fedora #ubuntu ImageMagick-devel rpm ubuntu at-style speaker sound ubuntu drivers xorg .xession dbi search_where greater than #python ziyi asc #debian
|
|