« first day (570 days earlier)      last day (4378 days later) » 

12:00 AM
Girlfriend goes to pick out a movie and comes back with LOTR. Yes
 
12:11 AM
haha lol
Is anyone able to solve a rewrite mystery?:P
 
12:29 AM
@RepWhoringPeeHaa Still cant get it to work.. where do you place your public folder? Since the htaccess redirects everything back to the index.php in my htdocs folder:o
 
1:03 AM
how to empty the tables in database after 24 hours in php. is it possible to do.
 
1:16 AM
use mysql in a cron
DELETE * from $table_name
 
thanks.do you have any links to study.
 
ok thanks a lot.
 
2:05 AM
@Dave TRUNCATE TABLE. Don't do DELETE *...
 
2:19 AM
hii
 
3:05 AM
Good morning all
 
3:17 AM
how are you ?
Hey @Paul
 
hi
 
@ircmaxell trippy intro
 
@ircmaxell Nice
 
@ircmaxell that's awesome haha
 
3:37 AM
that was cool, watching a gource for perl looks a lot more stable.
 
Gawd..I feel so sleepy.. real sucky morning..
 
what's the difference between a specific controller lets say users_controller.php and user.class.php in a framework ?
 
there's a difference? @Nick I thought the '.class' convention was just for naming of classes.
 
yeah so whats the difference between them? do they mean the same thing?
@ShyamK Im confused
in the terminology
 
3:53 AM
@Nick I'm guessing that the '.class' format is to specify a class of some sort, whereas the _controller format is used in the MVC model where there has to be separate model view and controller.
I'm not sure though
 
"...to specify a class of some sort..." care to give an example of what some these classes might be ?
@Paul I'm building my own framework but i'm not sure what's a standard directory setup. Do you have anything I can read on or any suggestions?
 
@Nick Say I'm not using MVC, Then I may have a list of classes for various purposes. For example I may have an admin.class.php to deal with all the admin functionality, or mabe a dbManager.class.php to deal with the database connections.

The use of .class is always allowed in the MVC format also, but I'm guessing along these lines. Please don't take my word for it. I maybe be right, but there's always that 99% chance that I'm wrong.
:D
 
Okay yeah that's what I was wondering
this framework stuff is hard haha
 
4:15 AM
making a framework is most definitely hard work. No wonder there aren't that many. There are loads of them. Sure. But its not like everyone is making one. :D
 
Yeah that's why it's hard to find good information about them
I'd have to say this chatroom is one of the best
 
@Nick Sorry I wasn't paying attention here earlier. I have almost finished building my framework. I've changed my directory setup quite a lot over the time. I was just looking at my own source with gource.
 
@Paul That's okay, do you use .class.php at all ?
and i'm having problems with my autoload, ugh
 
@Nick Namespaces are a good idea. Also, I think your directory structure should mimic your namespaces so that your autoloader is easy.
 
Hello, should I decrease the number of <?php and ?> in this code? I have added then to make things easier for myself. Is that going to affect performance?
 
4:20 AM
I've never heard of Namespaces haha, wikipedia here i come
 
Here is my framework base directory: github.com/Evoke-PHP/Evoke-PHP and here is where the code starts: github.com/Evoke-PHP/Evoke-PHP/tree/master/php/src/Evoke
Namespaces are really good to ensure that basic classes that other people may have implemented like Controller or View don't interfere.
 
How did you get good information on structuring your framework? Do you look at open source frameworks? I always feel like I'm doing the wrong thing
 
I have rewritten it a lot of times. Each time I become happier with it. I looked at other frameworks, but it takes a while to be sure of what you like. How much of your framework have you written? What are your goals for it?
 
I've never taken any school for programming so I'm just building to learn. I wanna be a good programmer
But yeah I have a project in mind
 
@geekpanth3r You have code duplication that you could remove with a function that would write a link for you. However, that snippet is tiny. If it works, just forget about it and let it work. Personally I would prefer pure PHP for readability (and just use echo to write the page from PHP - actually it isn't what I would do, but for a beginner it is good).
 
what features are you wanting to provide with your framework?
 
i am learning the basics of using backbone.js with codeigniter.. can someone tell me what feature of backbone triggers a submit button to send data to database
 
I guess I'm not really building a framework.. ? I'm building an application
 
@Paul Do you forsee any performance issues that it can cause? none at all? good to go?
 
but so far i want. seo friendly urls... /users ... /gamerequests .... user system, search,,
but i want to build the framework too
 
@geekpanth3r No, repeated <?php ?> shouldn't make a noticeable difference.
 
@Paul got it, thanks!
 
I'd encourage against writing a framework by yourself (I can't talk though, because that is what I have done). I can recommend some that are being written by the room regulars that you may be able to help with though.
 
@Paul I respect you saying that but like i said, I want to be really good so even if it turns out bad and broken, I'm constantly improving.
 
github.com/rdlowrey/Artax github.com/gordiansolutions/reefknot github.com/PeeHaa/MicroFramework or mine: github.com/Evoke-PHP You could certainly learn some things from any of these, even by trying to use them. You might see what works and doesn't work.
 
4:46 AM
Bookmarked! Thanks
@Paul You're probably right, I'm going to be wasting alot of time.
 
One thing that I want with my "framework" is that it should not be a framework, but it should be a library.
 
@Paul What's the library?
 
So I have worked hard to remove any hardcoded ideas for how it will be used. Like having set routing patterns, directory locations etc.
 
Yeah makes sense
 
@ShyamK github.com/Evoke-PHP/Evoke-PHP but it is still not quite ready yet. It is very close.
 
4:50 AM
@Paul I understand that a framework has loads of code that's already doing the work for you and that you just import specific modules where required and then call the functions already written in them. Right?
 
man why isn't autoloading working ? github.com/nybouchard/Flawk-Framework/blob/master/…
 
@Paul This is a library? or a framework?
 
@ShyamK Mine is a library because you can choose exactly which objects you want to use, and configure them for how they should be used. The scope of my framework is to provide customizable routing, content-type negotiation, dependency injection, controllers, data mappers, data models, content writers and views.
 
@Paul wow tonnes of code. :) Gonna take me years to look through this completely :D
@Paul so CodeIgnitor is a library too? or a framework?
 
I define a framework as something that controls the way you work with it.
(I don't like to be told how I should do things, so a library allows me to tell the objects from the library how to work).
 
4:57 AM
Yeah I agree, that's why I would consider my application as a framework.
 
@Paul Hmm so I like frameworks.. The power of free will :D
*I like libraries
crap
 
No, its the other way around. A library frees you, a framework mak... yes
 
my bad..my bad
 
lol, you fixed it before I said the same thing as you.
 
:D
 
5:02 AM
@Paul Have you implemented user classes?
 
can somebody help me pick up backbone.js..
 
@Nick No, not yet. I think eventually I might put that into Evoke_More. I'm going to try to keep the main library fairly minimal.
 
fair nough
 
am working with codeigniter..

http://stackoverflow.com/questions/10479772/trigger-submit-event-created-with-codeigniter-with-backbone-js
 
@Nick Consider using PHP_EOL to replace you definitions for` \n`, \r and \r\n.
 
5:11 AM
@Paul Will do
@Paul I can't find how he's including this class github.com/PeeHaa/pieterhordijk.com/blob/master/…
 
I followed the requires out to here: github.com/PeeHaa/pieterhordijk.com/blob/master/…
Actually, So many linked requires is an issue if you ask me.
@Nick By the way, none of the frameworks I listed are probably ready for serious use, but they would be good for learning.
 
@Paul Yeah I'm taking it in that way, it's good for trying to wrap your head around the concepts
lol I can't find the library in Peeha's MFW github.com/PeeHaa/MicroFramework/tree/master/MicroFW/MFW
 
No, one up from there I think.
 
5:23 AM
mornings
 
morning tereško
 
@tereško morning
 
5:45 AM
posted on May 08, 2012 by Cal Evans

Blog: http://http://caseysoftware.com/ Twitter: @hcaseysoftware Show Notes: http://austinphp.net/ RestFest Sponsored by: Engine Yard

 
morning @tereško
 
jay
5:57 AM
good morning
can any one tell me what is this meaning
$categories = array();
 
Sam
categories variable was declared as an array
 
jay
k
thanks
 
jay
but array is empty
 
Sam
you haven't stored anything in it; so, yeah.....it'll be empty
 
jay
6:01 AM
while($row = dbFetchArray($result)) {
list($id, $parentId, $name) = $row;
in this what is list
 
jay
thanu vary much
soory thank u very much
 
Sam
lol.....you are welcome
 
hey @Sam
 
Sam
@Nick hey @Nick; how's it going?
 
6:07 AM
Not bad, and yourself ?
 
Sam
good myself....isn't it past your bedtime? :P
 
yeah i was wondering the same for you haha
no it's going to be a late night for me
 
Sam
I just woke up
 
haha nice
 
Sam
crashed earlier
will be going back later
 
6:13 AM
ugh having problems with my autoloader
 
@Nick What errors are you getting?
 
nothing it's just not loading
 
Sam
hi @Paul; how's it going?
maybe the wheels need some grease....:P @Nick
 
lol what's that suppose to mean :P
 
hello @Sam Things are good thanks. I hear you are good too.^^
 
Sam
6:17 AM
@Paul; I get to play with the computer; make money; work out....and a whole lot of other stuff; life's good...:D
 
<exhale> I wish i made money
 
Sam
lol.....garage door metaphor;
lol....@Nick; you are a programmer, you'll start making money in no time
 
you bet ;)
 
Sam
of course, since you are in Canada, I'm not sure how much you'll be allowed to keep after taxes...:D
 
LOL! oh well free health careeeee
:D
 
Sam
6:20 AM
lol.....nothing's ever free; someone's gotta pay for it
how's your framework progressing?
 
ugh not very good, I'm reading other peoples source codes right now
 
Sam
lol....poor you; here, have some coffee
 
lol I have coffee
 
Sam
ok.....have some donut
:P
are you learning Objective-C too?
 
umm not right now, this summer though.
 
Sam
6:31 AM
I'm not sure if I should swallow my hatred of Apple to learn Obj-C, or just stick with Android
for the time being, I'm going for android
 
mmmmmm, apple fan boy don't be dissin' :P
 
Sam
lol.....I hate apple fanboys......:P; all those boys with shiny toys, with glazed eyes and dripping tongues over anything Apple does
 
It's because they make good products
and I can't consider myself a fanboy haha, I still have 3GS and no ipad haha
 
Sam
nope; it's more than that; I think it's more of something in those products that make them crazy; maybe some subliminal, electromagnetic frequency messages, maybe....:P
the only time I'll get it is if/when I start developing in it
hi gordon
got another article for me to read?
 
@Paul Your framework doesn't have a route system in place eh?
 
6:41 AM
mysql+addslashes -_-
 
and die
 
@Nick It has a customizable routing system. I just created a gist of an example site usage: gist.github.com/2633084
You can see the rules that I use for my application under the URI Routing comment block.
 
weird you're using regex to check the uri?
 
@Nick regex is just one of the options I provide for my rules. The rules I have defined so far are here: github.com/Evoke-PHP/Evoke-PHP/tree/master/php/src/Evoke/HTTP/…
That reminds me, my StrReplace rule sucks. It shouldn't take an array of subRules.
 
@Paul I'm lost on how I should be setting up my autoloader,, and the things I should be loading.
 
6:55 AM
I load everything via the autoloader. The only thing I don't are the two files that define the autoloader (its class and the interface which it implements). It works well.
 
jay
hello can any one help me
i want when i click update produtc
then
in modfy page
 
@Paul Namespaces eh? Mind linking me to your autoloader
 
jay
category id show in drop downbox
 
@jay What have you tried ?
 
Sam
@Paul; can one serialize a class object as cookie?
 
6:58 AM
@Nick github.com/Evoke-PHP/Evoke-PHP/blob/master/php/src/Evoke/Init/… Mine is quite standard, except it has the idea of authority added to it.
@Sam See this: stackoverflow.com/questions/132194/… I don't recommend doing it though.
 
Sam
@Paul thanks
guess I'll have to query the db every time a page loads; no biggie
 
7:13 AM
@Sam Yes, the benefit is that your server won't have to keep all of the session data.
 
Sam
I try to avoid sessions as much as possible; I prefer cookies
let the users keep their info
on their systems
 
@Nick echo $path; and echo something in your if (!is_readable($path)) {
 
It's not echo'ing anything in the loadLibrary function
 
@Nick , "does not work" is not a valid error message
 
there is no error message
 
7:22 AM
@Nick You should check spl_autoload_register, it can return false on error.
 
what does this error mean `XML Parsing Error: XML or text declaration not at start of entity` i've added like dis... <?xml version='1.0' encoding='utf-8'?>

<?php
 
Sam
@pbvamsi remove that XML declaration; it's only for XML files
 
even if i remove dat, am getting error...XML Parsing Error: XML or text declaration not at start of entity so i've tried to add it
 
Sam
is the file an XML or PHP file?
 
i dont use xml in any of my file, but its showing this error..
its php file, but it comes up with this error
 
7:29 AM
where does it come up with that error?
 
Sam
well, check again; that is an XML error; you are using XML somewhere
 
XML Parsing Error: XML declaration not well-formed
Location: http://localhost/ref%20proj/ajax_chat-0.8.5/ajax_chat-0.8.5/chat/
Line Number 1, Column 15:<?xml version=\"1.0\" encoding=\"UTF-8\"?>
where as in line no 1 its <?php
 
where does that error occur?
 
at line one, where as in line one its php starting tag as <?php
 
in the browser?
how are you viewing that error?
 
7:30 AM
ya, in the browser (firefox-epic, not checked with others)
 
and are you serving it from a php enabled webserver?
 
yes
 
then why does it say <?php? if the page was interpreted before it was sent to the browser there shouldnt be any php in it anymore. the only other reason would be that you are trying to load a php template with one of the xml extensions and thats causing an error.
 
on my first line its php opening tag, no where in the entire project i've used xml, even though its coming with that error
 
is the error page all yellow?
 
7:34 AM
yes, it is all yellow
i tried to prevent this error by libxml_use_internal_errors(true);error_reporting(0); but failed
 
of course. you are sending the page with an xml header. firefox will treat it as XML and apparently the page isnt interpreted, e.g. your webserver is not php enabled. or the page writes <?php somewhere on the page.
 
am using firefox 13.0 uptodate, from 3months am using same 2 run php scripts
xml header am trying to place for the only cause of avioding that error. actually my first line is <?php even though its coming up with that error. so am using that xml validator on 1st line, <?php on second line...ofcourse no where in my project am using xml
 
<?xml version="1.0" encoding="UTF-8"?> is not an XML Header but the XML Prolog
I am talking about HTTP header
 
k, then pls suggest me what i've to do know
 
your code either has a header('Content-Type: application/xml') somewhere or your webserver is set to serve XML by default
and you get the error because in XML <?php is a processing directive and not php opening tags. actually it's just <?. XML doesnt care for the php part.
 
7:41 AM
but i've not used that header any where
 
well, then it must be magic, right?
 
sorry, i dont know sir
 
open firebug, look at the response header. what does it say for Content-Type?
 
pls give me a moment to download that
infact to be clear i've downloaded it from sourceforge.net/projects/ajax-chat/files to embed into my server
@Gordon its working online, i've made all custom alterations as directed and at final leap this happened
 
jay
can i delete product image in folder when i delete product
plz tell me
 
7:46 AM
@jay yes
so long as you are working with a turing complete language.
 
jay
yes
is it possible
 
@pbvamsi Ok, one more time :) When a webserver gets a request to a PHP resource, it will run the PHP code. PHP will prepare the result page in that process and hand the page to the webserver for delivery. The webserver will return that result page to the client/browser. The browser will render it according to the set Content-Type. Your webserver apparently serves the page as XML and the page contains <?php which it shouldnt if the PHP was execured prior to delivery.
 
3 mins ago, by Paul
@jay yes
 
jay
hello paul
can u tell how can i do this
 
@jay am I going to do it for you? no
 
7:50 AM
@Gordon okay :) do i need to change some thing in this line $config['contentType'] = null;
 
@pbvamsi I dont know. I've never used that chat thing you linked. you have to find out yourself. Im just telling you what's likely causing the issue.
 
jay
can u send me a link for help
 
today heard a depressing statement
> we are the last generation to die from natural causes
 
@Gordon thanks
 
7:51 AM
@jay php.net/manual/en If Gordon's didn't help, then this one. Seriously.
 
jay
ok thanks
 
@jay , you have to ask a serious question to get a serious answer
 
jay
yes
 
Sam
@tereško read that the planet's gonna blow up in about a billion yrs; of course, I might still be alive to witness that
 
jay
i want to delete file which i had to upload at insert time
how can i do this task
 
7:54 AM
8 mins ago, by jay
can i delete product image in folder when i delete product
 
@jay go read those links now.
 
this was a question with a yes/no answer
 
jay
yes
k
 
@jay , in php you can do it with unlink() , as long as you have the write permissions on that file
as people might be able to tell .. i am bored out of my mind
 
morning
 
7:59 AM
morning
 
morning
 
morning
 
morning
 
@Nick @RepWhoringPeeHaa is one of the framework writers I listed earlier.
 
@Paul Yeah I've been going over his MFW for a couple weeks now
trying to wrap my head around it
@RepWhoringPeeHaa i can't my autoloader to work github.com/nybouchard/Flawk-Framework/blob/master/…
 
8:05 AM
I was wondering, how dangerous is it to json_decode($_GET['userInput'])?
 
46 mins ago, by Nick
It's not echo'ing anything in the loadLibrary function
 
This is so discouraging haha
 
It can't be calling that class, so you won't find the issue there.
See if you can find something that will echo, and work your way from there. (Maybe your rewrite rule isn't sending it to where you think?)
 
maybe i'll play around with that a bit
 
check your web server error logs.
 
8:11 AM
@Paul <exhale> you were right, my htaccess was stopping it from working
thanks @Paul
 
@Nick No problems, good stuff.
 
@Christian im not aware of any security implications when json_decoding user input. However, the same precautions as usual have to be taken when using the decoded data afterwards of course, e.g. you cannot trust the decoded data.
 
Sam
@Nick of course he's right....he's a guru....:P
 
haha yeah,, doesn't even have to look at my code and knows whats wrong
while i spent a good solid hour trying to make shit work
 
Sam
here.....have more coffee
 
8:13 AM
@Sam I wish. Its the steady stream of mistakes that I make that keep them fresh in my mind.
 
@Gordon ok.... well I've decided against it anyway...I somehow feel better seeing a slightly larger form post that everything in just one big blob.
 
Sam
@Paul live and learn, right? :D
 
@Paul This may be a stupid question but the autoload goes by the file name or the class name?
 
@Nick By the class name, not stupid at all.
 
@Paul hence why people use namespaces correct?
 
Sam
8:17 AM
shouldn't the class and filename ideally be the same?
 
no, namespaces are for making class names unique and providing another layer of organization. I like to make my class name the same as the file, and put it in the directory according to the namespace.
 
@Sam ummm not really. you could have something like auth.php with class library_auth so that when you autoload you can explode "_" and implode "/"
 
Sam
@Nick if you have to do that, you are giving the system an extra work to do for no apparent reason......IMO....:P
 
@Paul I guess it depends how you autoload
@Sam concept comes from @RepWhoringPeeHaa github.com/PeeHaa/MicroFramework/blob/master/MicroFW/MFW/…
 
@RepWhoringPeeHaa , about the same file ... sooooo .. it can return either false of null. That's a bit questionable , wouldn't you say
 
8:21 AM
Morning everyone!
 
@Sam ...but i see your point
 
Sam
@Nick I'm just learning myself......so, what do I know? :P
morning, Mittchel
 
@Sam Same haha
 
@tereško Owh I do agree
 
hey guys
I have a question about json_encode
 
8:30 AM
asking usually helps
 
I was about to.
 
jay
hello tersko
thank u for help
 
> One way to address these CGI issues is to reject the request if the query string contains a '-' and no '='.
right... :|
 
@electrickoolaid42 still waiting...
 
lol, I appreciate the desire to help, normally no one is in these chatrooms and responding
I'm not quite prepared, posting the relevant code to a blog instead of trying to inline it here
just a sec
 
8:35 AM
@electrickoolaid42 posting the code to a blog? pastebin.com
 
...I can't believe I didn't think of that. Already almost done, in any case
okay, here
I'm trying to grab comments from an RSS feed (for a wordpress blog) in PHP and display them using javascript
it's a two-dimensional array, and I don't quite know how to interpret the output, and I especially don't understand why it appears both of the elements have an indexx of 0 in the json encode
unless I'm just interpreting it wrong
wait, wait a minute, the output seems slightly different now than the last time I was looking at this
nvm, I lied, it's still the same
separated out it looks like this
 
damn the internet is still retarted slow here :(
 
@RepWhoringPeeHaa are you still having problems with video streaming ?
 
I have issues with simple browsing ATM :(
 
the third element of the 2nd dimension should contain the content of the comment, not sure why it doesn't
but I'll work on that after I can figure out how to interpret the rest of it
also I'm really not trying to direct traffic to my crappy blog, it was just the most convenient place I thought of to post the code
because it's early in the morning and I forgot about pastebin
but like, and maybe this question would be more relevant in the javascript chat, how do I call upon specific elements? If the first dimension is 0 in both, how will the client machine distinguish between the first [0][1] and the second [0][1]?
 
8:44 AM
@Paul What is the $authoritative; in your autoloader?
 
Sam
@electrickoolaid42 if it's a single array, then that situation is impossible; there'll only be one [0][1] for a single array
 
@tereško question... Do you know how to fix this markdown issue, where there is a list and a code block right under it. I don't want the codeblock to be in the list: gist.github.com/2631006
 
@Sam, I'm probably misinterpreting the code then, but see my output? it looks to me like there's two [0][1]'s (and 2s and 3s)
 
Sam
@electrickoolaid42 do you have the code (or at least, a link to it)?
 
wait .. no
 
8:48 AM
yes, posted a little above
unless it didn't post the link for some reason
 
@electrickoolaid42 I don't think you did, I was waiting for it
 
@Nick I use $authoritative for an autoloader that has authority over an entire namespace. I consider it exceptional when an authoritative autoloader cannot load a class within that namespace. So, I can throw an exception in that case which works out better than the fatal error that I would have ended up with without the class being loaded.
 
it tells me "you can perform this action again in 1 second"
and apparently doesn't post the link?
do I have to have more points or something to post a link, or are links forbidden, or....?
 
Sam
try again
 
just di
 
8:49 AM
@Paul oh okay makes sense.
 
blog.sykonaut.net/?p=45
hey there we go, I think... it's not clickable though
but I trust you guys can copy+paste
 
Sam
can you interpret json?
 
 - foobar

<span></span>

    code
    {
        asdasd
    }
@RepWhoringPeeHaa , this will work
but it is a horrid hack
also .. on a different note :
> OR might be just personal preference, but c'mon who uses OR in PHP. And why would you?
 
Sam
@electrickoolaid42 once you decode your json, you have an array you can access via array[0], array[1], etc
 
8:53 AM
can I interpret json? I only just started working with PHP and JS two days and about 6 hours of coding ago... I know arrays, I program in java all day at work, and I think I can interpret the json_encode, but I don't exactly have a lot of experience in it, that's the basis for my question
 
@RepWhoringPeeHaa , OR has higher precedence then = .. there are usecase for it
 
okay, except it's a two-dimensional array and it appears the first dimension element value is 0 for both comments I'm gathering information on
 
@electrickoolaid42 You could var_dump($cmnt_array); in PHP to see the structure you are encoding.
 
@tereško yup correct. However have you check out the use case?
@tereško It is a horrid hack, but better thyan anything I did come up with
tnx
 
good idea, let me try that
 
8:55 AM
Might change the text though
gawd this connection is bad
 
Sam
@electrickoolaid42 no, it does not; once you format it properly, you'll see it more clearly
 
okay, then new question, how do I format it properly? I see no other way to break it down
 
Sam
@electrickoolaid42 you generated all those from a single json?
 

« first day (570 days earlier)      last day (4378 days later) »