« first day (648 days earlier)      last day (4300 days later) » 

2:00 PM
:D That's true, but there is logic and I like that
 
@tereško Is APC something I can implement into my site later on as it grows and as I gain experience or does it have to be implemented right away?
 
@Alec It enters in the cache invalidation problem, when to tell your cache expired, if you can you should set a timeout or ideally when a new thing is posted you would remake the cache (That enters the problem that if new data is inserted too frequent and you make and remake the cache, the whole cache system would take more time than a non cached version)
 
@Alec , why would you need to ? Is the data written into the database by some external tool which is not php ? If no, then you just update the cache every time you write to the database . Also, each entry has a limited lifetime.
when the entry is not in the cache , you fetch it from DB , store it in cache with some lifetime and you are done
whenever you write to the DB , you either invalidate the old cache entries , or update the cache entries with the new data
 
Word
 
@tereško No it's inserted via PHP. I don't have a whole lot of experience with back-end programming like this so I may be slow to grasp most of it. I take it as that's something I can implement later on when I need to.
 
2:04 PM
morning
 
@NikiC morning
 
@NikiC Welcome.
 
@NikiC morning
 
@Alec , you can implement caching at any point .. usually it is the point when you DB begins to choke ( which , from your description, seems to be "right now" )
 
user895378
2:05 PM
@Alec The whole point of having a well-design, loosely-coupled architecture is that you can easily add or change anything with minimal pain.
 
user895378
If you design your application well, adding anything down the road should be possible.
 
also , the ease of implementation will vary , depending on your existing code
 
Releasing code as "Open Source" is not an excuse for releasing garbage code...
 
@ircmaxell 10/10
 
user895378
@ircmaxell So true. The "It's open source, you should help fix it if you don't like it" argument gets so annoying.
 
2:07 PM
@ircmaxell , i think you have missed the point of /r/PHP
 
.. or the community that frequents it
 
@rdlowrey @tereško Alright, thank you. Your input is much appreciated, sorry if I seem to be slow to get things. I just began PHP last night but I seem to be getting pretty far.
 
@ircmaxell , from the yesterdays comments i was expecting a 40+ page dissertation
@Alec , any experience in other programming languages ?
 
@ircmaxell I don't see the point of trying to criticize a mass such as reddit. There's a good reason why they're all at reddit and likely not on any other sites.
@tereško Yes, Java and some C++. .NET languages too but I'm not so fond of those.
@tereško Don't really know if calling them ".NET languages" is the proper definition, but basically ones where you're locked into the windows framework if you want to get anything accomplished.
 
2:11 PM
@tereško No, that's friday's post
 
I just tested Blowfish on shared hosting.
<?php
if (CRYPT_BLOWFISH == 1) {
echo 'Blowfish: ' . crypt('rasmuslerdorf', '$2a$07$usesomesillystringforsalt$') . "<br>";
}

?>`
i Don't get any output may i know why is this so
 
oh .. checks the calendar
 
@BasicBridge have your host upgrade to 5.3+
 
oh man i got killed last night at the gym.
 
ZOMBIE!!! RUN!!!
 
2:12 PM
holy god, trainer worked me to hell
@ircmaxell god aint that the truth
 
@BasicBridge Some rather useless input but maybe it's not running because CRYPT_BLOWFISH doesn't equal 1? I've had some moments like that in Java with IF statements.
 
try hash_algos() and see what is available to you
 
Quick OOP question: I've read that var is depreciated in PHP 5. I keep finding statements like var $item = null; Is there any reason I shouldn't replace them with private $item;?
 
@ircmaxell jQuery....
 
Hrm, my post indicating that the utility class is violating the GPL has been downvoted: reddit.com/r/PHP/comments/x3rbr/…
 
2:12 PM
@ircmaxell thanks i got it
 
@tereško has nothing to do with crypt()
 
HCP
@THOmas hoi thomas. ben je thomas alderse baas ?
 
trainer has me eating 6 meals a day, holy crap im stuff howtf am i supposed to do this >_>
 
@ircmaxell , hmm .. i had the impression that it does .. my mistake
 
posted on July 25, 2012 by Anthony Ferrara

In response to last week's ask for questions, I received a number of questions that I'd like to address. Since it would only do the question justice to have a dedicated post for each question. So I'm going to try to do one post per week on a user-submitted question (probably on Wednesday, but no promises). This week's question is a rather abstract one: I've been learning a lot about service lay

 
2:15 PM
@SomeKittens you should replace them with the apropriate access method, if it's public, private or protected instead of var
 
@FabioCosta Ok. Should I worry about not initializing them to null?
 
@SomeKittens nope
 
Thanks. I want to make sure I don't pick up bad habits from this outsourced code.
 
@gorelative less fiber. easy in easy out.
 
If any of you were curious, this is what I've been working on: plzfollow.us/d1v1nx I know most of you are Christians, but yeah. I'm working on the design first, then the PHP. Almost done with the design stage. The confess page is outdated, I need to update it to what the Request page looks like. Old design on the confess page didn't work well with computers that had smaller screen resolutions.
Kind of wanted to make it so everything was in the home page but I didn't think that would be that optimized.
Haven't started on View page yet.
 
2:22 PM
@rlemon dont you mean more fiber?
 
@Alec most of us are atheists or agnostic
 
I'm curious how you arrived at that conclusion too @Alec
 
@tereško I'm aware. I was interested in showing the web page, not starting a religious debate.
 
@gorelative more fiber + lots of watermelon / liquidy foods for softening :) and you're golden!
 
@MikeB me 3 where in the php manual does it say one of the sys requirements is the developer must be christian?
 
2:25 PM
also the "confess" page is a bit creepy .. are you sure that it does not have a large DB table behind it ?
 
@MikeB I think Alec meant "aren't Christians"
 
@tereško agreed, couldn't you just put a disabled textbox and a picture of a microphone so i can speak into it? Im not comfortable typing into the textbox.
 
@SomeKittens Just noticed that typo, yeah sorry.
 
and this looks specifically Catholic, not general Christianity
 
@SomeKittens The question remains.. how would one arrive at EITHER conclusion?
 
2:27 PM
It's a safe bet to say that the majority of people in a community like this aren't religious.
Just like it's a safe bet to say that the majority are male
 
LOL that's never a safe bet
 
OMG
 
@MikeB Not trying to sound rude but I'm pretty sure I'm the only Christian in here. Anyways, this is a PHP room not a religious debate channel.
 
@Alec All I'm asking is how you arrived at that conclusion. I've never seen anyone mention religion anywhere on StackOverflow or Chat
 
I'm actually having trouble with some regex. I thought '?' was for something regardless. I.e. /a?c/ would match 'abc', 'a!c', 'a3c', etc. Is there no single meta character for doing that?
 
2:29 PM
@MikeB It's popped up in the JS room
thought everyone knows the JS room is always super on topic
 
here are the issues with the current design:

- it makes small children bleed
- the color scheme has to be changes
- if you need it to work on different screens, use dynamic size units and `max-width`
- borders add to the physical size of elements , compensate for that
- do not use fixed offset from left for the container
and when you have solved all this : try to add a design
 
My actual issue is '/^e????ee?$/' gives a Compilation failed: nothing to repeat at offset 4
 
Actually, "makes small children bleed" is a known issue with PHP
7
 
@Alec Jewish here....
 
2:32 PM
Hi all ^^
 
@Mike Howdy
 
@SomeKittens , no , it has nothing to do with php. Do not blame your shitty code on PHP.
 
@MikeB How are you?
 
Dandy
 
@tereško I usually blame it on outsourcers.
 
2:34 PM
me im pretty good ! After 4 or 5 evenings spent to search how to make phpunit and selenium work together i found out how :D
 
Am I the only person that doesn't find Tracy Morgan amusing at all? How is he famous?
 
He's actually a pretty down to earth guy
 
@SomeKittens I blame the alcohol. But then I turn to alcohol due to self loathing from shitty code. it's an endless cycle.
 
Tracy-who?
 
2:35 PM
yea that was a good one
 
@Event_Horizon why would you even know who that is ?
 
@tereško Commercials
 
And if you don't realize, the peak happens at 0.1337
 
what are commercials ?
 
2:35 PM
don't you have adblock ?
 
@ircmaxell lol
 
But now, i'm searching how to make someone force donwload a file without creating a physic file... Can we do this?
 
@tereško At home I do
 
is it horrible to have a column name in mysql date
 
HCP
I didn;t get the funny part. can someone explain plz?
 
2:36 PM
@ircmaxell Just realized that, awesome
 
@MikeBoutin attachment header
 
@tereško with this, i can force downlaod a xml file from a php script?
 
@rlemon , why not time ?
 
@tereško semantics. Although I store a timestamp I really only ever care about the date and not the time.
 
HCP
actually i think i get it i just think it isn't that funny
 
2:38 PM
@rlemon , "date" actually implies precision to a day .. "time" - to a second
@HCP , maybe you should seek professional help
what the hell are you even talking about ?
 
yes and I am recording to the second but using it only for the date (day) - however it does not matter it is not a reserved word... I just didn't know if it was a huge red flag or anything :/
 
@GeoPhoenix lo
med
 
PLB
I've asked this question on SO but no real answer, unfortunately. I retrieve annotations with simple annotation parser. where is it better to "save" this metadata?
 
so well i dont' have php 5.3 on server.
Is it good to use crypt md5 for passwords
 
HCP
2:41 PM
@tereško I'd take it if i were a hot girl. Know any nice girl ;-) ?
 
@PLB , wow .. and you waited for whole 30 minutes
 
@PLB copy and paste it into notepad using CTRL+A then CTRL+C then open notepad and CTRL+V then CTRL+S (give it a name, I suggest Unicorny) ENTER then ALT+F4 to close notepad... :)
 
HCP
@tereško like a girl that gives professional help with happy ending :-))
 
@HCP , "nice girls" don't do that .. also , completely offtopic
 
HCP
@tereško which topic might that be ?
 
2:45 PM
.. and there goes another user in the ignore-list
 
@tereško what do you say about CRYPT_MD5 for passwords.
 
HCP
@tereško if girls do that, I would consider them nice ;-)
 
@BasicBridge its not crypt its hashing
 
PLB
@tereško Either I misunderstood what you've said or you misunderstood my question. I'm going to use this metadata like symphony does in its models (yes, I am reinventing wheel). So what's the best way to use annotations in my script for setting rules, defining default values and so on
 
he
y
 
2:46 PM
You should use it with an arbitrary salt value
 
@BasicBridge , i say "use PBKDF2, if you cannot use blowfish"
 
@jami crypt — One-way string hashing
 
how can i initialise a date in php usind yyyy,dd,mm..
 
@BasicBridge CRYPT_SHA512 or PBKDF2 with SHA512...
 
2:47 PM
hello
 
@jami it's crypt(). It's the name of a library for doing the hashes for password storage
 
@anybody:how can i initialise a date in php usind yyyy,dd,mm..
plese help
...
 
ah i get it.
 
Now live in an AppStore near you: watch servers implode as they try to process many simultaneous purchases of large cats.
 
Speaking of large cats....
 
2:49 PM
@deceze i was looking at the changelog for mountain lion.. wtf? you get messages app, and icloud actually working now? thats worth my $20? No thanks, ill stick to Lion :)
 
@rlemon , please don't spam
 
@tereško lol... ok there.
 
I wonder how he came to that conclusion :D
 
@deceze , common sense usually takes time to penetrate blood-brain barrier
 
@ircmaxell , that guy never gives up
 
@ircmaxell Yes, you must. :P
 
@tereško Wasn't that that wanker of the "master university of good good practices and general good stuff written in php"
 
@tereško Just shows that us programmers aren't as rational as we like to think. Get off on the wrong foot, and all arguments are ignored, however valid... :D
 
@PeeHaa , yes , yes it is the same one
 
2:54 PM
@PeeHaa which is exactly the problem with that comment
 
wait what the hell...util.php
 
@gorelative it's today's running gag in php chats all over the world
 
@tereško hehe
 
so some kid really released this? Or is it a gag..
 
2:56 PM
@gorelative Company Research In Motion :D
 
user895378
it's no wonder RIM is going down the tubes ...
 
@PLB i was actually implying that you are impatient and have a feeling of entitlement
also , the whole "annotation" thing seems misguided , and feels like something a asp.net developer would try
 
user895378
@PLB It's not re-inventing the wheel if you do it the same way Symfony does it ...
 
I like abusing annotations the way Symfony and Doctrine2 have started doing. As long as they don't get too complex
 
BTW, here is a hint: if you want a large amount of high quality answers , create a bounty
200 should be large enough to attract people
 
on what grounds (tl;dr)?
 
> As I am looking to improve my own coding style, I am hoping that a few experienced people will comment so that I can be certain that there is consensus amoung the experienced folks.
That?
 
not constructive and off topic (but it has an open bounty, so we can't close-vote)
 
@MikeB I avoid them unless it will be language standard to access those annotation instead of reflection docblock parsing
 
user895378
3:03 PM
@MikeB Ohh not me ... IMHO annotations are terrible way to do anything in production code. They're fine for meta information to generate peripheral code (like unit tests). But using annotations for dependency injection or populating models is the height of stupidity as far as I'm concerned.
 
@jami What's your beef with reflection? Too slow or hacky?
 
user895378
Your application should run on code, not comments.
 
to slow
 
why are you using word models (the plural form) in context of MVC ?
 
user895378
@MikeB No, I use reflection a lot. But not for annotations.
 
3:04 PM
it was not called MMMMMMVC for a reason
 
user895378
@jami And reflection isn't too slow. Not to mention if you're worried about the speed you have an opportunity to cache the reflection every time you create it.
 
user895378
Anything is "too slow" if you do it wrong.
 
@rdlowrey But code should read well too.. especially in model-classes where your business logic should be understandable to laymen. I have this pastebin from the other day to illustrate pastebin.com/egTMwsZm
 
user895378
I didn't say code shouldn't read well. It most assuredly should. But that is not the same thing as using annotations as code.
 
user895378
@jami Reflection is an order of magnitude faster than disk access and several orders of magnitude faster than retrieving information from a remote database ...
 
3:05 PM
A business analyst should be able to read that and understand that this class has a website field and there are a couple validation restrictions associated with it.. I could write the same thing with PHP in a different method to attach the validator or whatever.. but then it's in a different place and difficult to follow
 
@rdlowrey you comparing apples to pears
 
$this->getField('website')->addValidator(new UrlValidator(array('allowed' => array('https'.... ... etc etc etc
 
user895378
@MikeB Code should be fully readable and comprehensible to someone who can read code. It's not plain text.
 
user895378
@jami Exactly. Reflected code is still code. It's not too slow unless you're doing it wrong or using it inappropriately.
 
user895378
@MikeB But you can achieve the same thing without annotations.
 
3:08 PM
@rdlowrey ever used the java taglib concept?
 
@rdlowrey True, I've only recently started playing with the idea.. but having your business analysts read your model-layer API and understand it is an attractive concept to me
Since that's where all your business logic SHOULD be, it makes sense that anyone should be able to read the API and immediately identify with it, regardless of their programming experience
 
user895378
@jami No.
 
user895378
Good code invalidates the need for most comments. If you need annotations to describe what your code does then you aren't writing your code correctly.
 
@rdlowrey ...
 
I don't need annotations to describe the code, it's just the cleanest way of doing so.. the alternative to @validate Length 32 is $this->getField('website')->addValidator(new LengthValidate(32));
 
3:11 PM
@rdlowrey gist.github.com/3151021 like this?
 
Sorry I just come in and saw something annotations. I hate them :) (I get the feeling I'm hating more and more stuff lately) :P
 
user895378
@rlemon exactly. If everything people wrote looked like that we could do away with docblocks altogether :)
 
@rlemon what the f does that do
 
@rlemon look for the IOCCC there you got better examples ;)
 
@PeeHaa What's your experience been with them? Symfony or Doctrine2?
 
3:12 PM
@gorelative try it out :P
 
Is there a IOPCC?
 
user895378
@MikeB Your example code in that case is imminently unreadable and exactly the sort of code that needs annotations because it's not written readably.
 
user895378
Jun 29 at 1:46, by rdlowrey
user image
 
user895378
Not to mention it's already part of a larger problem (the ORM lie).
 
@rdlowrey so you never saw a "in your opinion"-good use of annotation?
 
3:16 PM
Hi guys am beginner for wordpress. can some one tell me how to remove symlinks in post.
 
user895378
@jami Not at all. I'm totally fine with how PHPUnit uses annotations, for example.
 
user895378
But if your code can't run without comments you've got a problem IMHO.
 
@rdlowrey This is a better example of annotations in a model pastebin.com/eqSPpPS3
Nothing about where the data comes from, where it goes.. foreign keys or any of that.. belongs in a mapper or elseware. But a layman could print the phpdoc/api of that class and understand everything
 
Hi guys .
 
@rdlowrey so if i remove some @expectedException in YOUR unittest your tests will fail. So your code is crap. Like u said
 
3:20 PM
Dont spam
Just tell us your problem. If anybody can and wants to help, they will.
 
user895378
18 mins ago, by rdlowrey
@MikeB Ohh not me ... IMHO annotations are terrible way to do anything in production code. They're fine for meta information to generate peripheral code (like unit tests). But using annotations for dependency injection or populating models is the height of stupidity as far as I'm concerned.
 
2 messages moved to recycle bin
 
user895378
@jami my application doesn't break if my unit tests fail.
 
teach me :)
 
stackoverflow.com/questions/11653042/post-value-not-set-when-form-action-javascriptsomejsfunction

return 'hello kitty';
return 'Batman';
 
3:21 PM
@rdlowrey ah ok. That mean annotation only outside the lib code for you
 
People always talk about comments lying because people can change code and not update comments.. but what if comments WERE your code (in a way)
 
user895378
@MikeB I understand what you're saying about readability, but in that case the annotations are part of a larger leaky abstraction (ORM). A simple, well-constructed data mapper is no less readable.
 
the comments wouldn't lie (atleast not in the same way as before)
 
user895378
@MikeB My response to that is: what if your code were your code?
 
user895378
not trying to be rude :)
 
3:24 PM
oh yes you try
 
@rdlowrey Not at all, I've been hoping to have this discussion :)
 
user895378
@MikeB Good to know some people can discuss the merits of an idea without assuming everything is a personal attack.
 
The thing I'm hooked on is being able to document your code and hand it off to someone who doesn't understand code. Annotations provide an opportunity for that
 
user895378
@jami Because my opinion of a coding practice is not a personal attack. Stop taking it as such.
 
@rdlowrey where is the discussion when you always set the rule of usage
right its "your" opinion
 
3:26 PM
@rdlowrey You're absolutely right about people abusing annotations.. I've seen some of Doctrine's annotations and they aren't readable, span multiple lines, groupings, etc.. it can get out of hand
 
it is not only "his" opinion
 
var iable,declaration,isDone,rightHere,
       me, you, us, fox, dinner, should;
should = function you() {
      return with (me);
}
(me && you) should("GET", some, dinner);
my code speaks for itself (bored on conference calls all morning. :/)
 
@tereško so it must not be mine
 
@MikeB First introduction was when using php unit. And I generally don't have any idea why it would be a smart thing to do.
 
@PeeHaa Fair enough, just curious where your experiences originated from
 
3:30 PM
I also think that phpunit use annotations in a smart way
 
user895378
@MikeB I completely agree with your goal of readability. But I don't think you should use a less-than-optimal coding practice to promote that readability. I suppose it could depend on who your audience is, though. If you're required to have code that Joe-Business-Analyst can understand, maybe annotations are your only option. Generally, though, the target audience is going to be people who can understand code.
 
Here is a nice nugget to chew on : in a well refactored code, you don't need any comments at all. All the methods do exactly, what you would expect, when reading the method's name.
6
 
user895378
@tereško +1
 
user895378
And +1 on that too.
 
3:33 PM
@rdlowrey I hope you never get an j2ee job. Because you would explode immediately if you write your first EJB :D
 
user895378
I'm working on a streak: 29 years without writing a line of Java. Hopefully I can keep that up :)
 
well .. of course there are exceptions ( especially if you start doing some mathematical magic )
 
user895378
and bug workarounds that I would totally go through and delete if I didn't have a comment explaining why they were there
 
@jami , was the intended to make us think that java is the holy grail of coding practices ?
 
@MikeB However I hate the abuse of annotations in general. That's was just where I first saw it
 
3:37 PM
@tereško no but that there is annotation stuff out there beyond the testing area
that was the point
 
@PeeHaa Then, does this make you ill? :p chat.stackoverflow.com/transcript/message/4669727#4669727
 
@webarto
@webarto
 
just blogged about Using the SPDX License List for Tagging and Linking - next time you add an @license tag in your source-code, get educated about SPDX license identifiers and links.
 
user895378
@hakre Useful to me. Thanks.
 
@MikeB , its extremely pointless
 
3:54 PM
that sucks
 
has anyone here ever had to export something to pdf from php? I have a report site that im developing and they want to be able to download a pdf of the report.
 
i have used FPDF for that
 
@gorelative im using ghostscript for that
 
@gorelative havent touched/seen the code for it for a long time, but we have that functionality
 
> Remarks about Deprecated PDFlib Functions
yeah looks like fpdf is my way out, now to write a CI wrapper around it.
crap, i hate CI
 
@rdlowrey cool, good to know. Let me know how you consider to use that resource. But now I'm off to bike to the swimming pool.
 
oh screw it, ill just force them to download a csv file or they can print to pdf, with the print driver.
 
when having a simple hash stored to database is it safe and simple to hash the message with the key and compare with strcmp == 0, the hash fetched from database?
 
4:16 PM
I'm getting old and grumpy. Why on earth would one indent PHP code with only two spaces :( stackoverflow.com/questions/11654164/prepared-statement
 
@PeeHaa I have that problem too :( Is it something to do with Mac? I don't understand wtf is wrong with \t
 
@webarto Uhmmmm are you sure you just told me about \t?
:P
When in an IDE which does tabs to spaces I hope ;)
 
4 spaces anyways :)
 
:D
I'm going home. I want to pickup the work on my blogging platform again
later
 
Yo
@PeeHaa Your cv-pls plugin stopped working for me
 
4:30 PM
I need help building a wordpress CSV uploader. I have all the wordpress actions that i need to post the post, but i want to be able to loop through a CSV and do these actions
 
thanks Geo, i tried that and I also tried tweaking it but doesnt work for my custom setup oad post types
 
hey guys , should a object, which handles cookies, be considered a mapper ? Or even part of model layer at all ?
 
@tereško sounds like a gateway
 
i am kinda thinking "no" , but that leaves me with no good palce to put it
 
4:40 PM
@thesanerone building the code on how it will parse your custom CSV, is up to you, and depends on CSV formatting, a couple of explodes/IFs and all that in a loop for each row
 
Geo, you make it sound so easy lol
 
ok .. "mapper" was the wrong term to use.
 
im an amateur at best. I've build a few plugins and all but I've never worked with csv files
i need some profe$$ional help
 
@thesanerone ask a question
@thesanerone also post a single 1-2 rows of your csv file
 
post_title post_content post_status user_email cp_price cp_street cp_city cp_state cp_country cp_zipcode ad_cat post_type
test test publish thesanerone@gmail.com 200 North Ave Chicago Illinois United States 60601 cars-trucks ad_listing
the first row are the headers
 
4:49 PM
dafuq
 
5:04 PM
@thesanerone wall of text.
 
@tereško i would put is as model to the persistence layer
 
if you have a report thats generated from the results of aSQL statement and you had a export to csv button on this report.. would you cache the queries results and when the link is clicked generate the csv file. or would you create the csv file every time the report is ran and store it in a tmp folder or would you run the query again when the link is clicked and generate sql statement.
obviously you'd want to cut down on the amount of duplicate queries so option #1 or #2 seems the best. Just not sure which of the two.. the query is quite taxing.
 
#1, but if the traffic is low enough #2 would be better
#1 is the safe bet, anyways
 
cache the file every 10min
 
@GeoPhoenix it has to be live data, so essentially i'd hash the connection_id of the person running the report and save a csv file named that.
 
5:11 PM
connection_id ?
 
@orourkek 25-50 users at any one time. Report takes an average of 3 seconds to run. So i need to find a way to cache the results between requests.. as this site uses codeigniter.. and it uses a view to generate the report..
@GeoPhoenix codeigniter generates a connection_id per query that you can use to reference the queries.
 
that sounds ok, use that
 
the caching on my CI project is quite rough, so I won't be of much help there
 
use wordpress, I hear it is the best framework
 
@orourkek just need to find an ideal way to pass a large amount of data back to the controller.. hmm seems like a question for SO
 
5:15 PM
how large are we talking, and from the model I assume?
 
yes model, my bad.
probably 1500 rows~ 20 columns
all text
i guess i could create a file with a timestamp and just clear the tmp folder ever ~30mins
and just ref that file in the link.. probably easier
 
csv to the rescue
 
yeah itll be a csv file for sure, as it opens natively in excel. Just struggling over whether i should store the results in a table, or create a csv file in a tmp folder.
ragagagsdagsdg
 
file
 
file in a database
 
5:22 PM
within a sqllite db file
 
what this message means InnoDB free: 2174976 kB while checking mysql database table with phpmyadmin
 
within a oracle dbfs
 
inside a VirtualMachine
 
stored in another dbfs? :D
 
inside the hard drive of military satellite
 
5:40 PM
@jami , why would Cookies instance be a model ?
 
hey guys
Can somebody help me understand this answer - stackoverflow.com/a/9848014/295508
 
@tereško utility?
 
@tereško because it should be sanitized and validated
 
Does that method really not cause any collisions as long as the ID is within 0 and 64^4 ?
 
@JohnP looks that way
 
5:46 PM
@jami it seems you have very strange ideas of what model is .. maybe you should read this : c2.com/cgi/wiki?DomainObject
 
interesting
 
@tereško so?
 
gods below .. why do i even respond to your highlights !? I should know better by now
 
@orourkek thanks, the bit operators are throwing me. Not really sure what's going on there and I hate using stuff without completely understanding it
 
@tereško cant a cookie be a outside entity?
 
5:54 PM
@jami I view Cookies as a storage mechanism, similar to databases
A model should be CRUD-able from either
 
saying "A Model" makes me thing you're talking about MVP
 
?
 
@orourkek MVP?
 
@MikeB always? How do you call the storage mechanism?
 
Model–view–presenter (MVP) is a derivative of the model–view–controller (MVC) software pattern, also used mostly for building user interfaces. In MVP the presenter assumes the functionality of the "middle-man" (played by the controller in MVC). Additionally, the view is responsible for handling the UI events (like mouseDown, keyDown, etc.), which used to be the controller's job. Eventually, the model becomes strictly a domain model. Pattern description MVP is a user interface design pattern engineered to facilitate automated unit testing and improve the separation of concerns in pr...
e.g. nearly every PHP "MVC" framework
 
5:58 PM
@orourkek Aye
 
If I had a User model (or domain object) I would call save.. it's the mapper's responsibility to dictate where the data goes. The mapper can indicate that the 'gateway' to use is Cookie, Database, Session, Webservice, Memcache, etc
1 or more of any of those
As a developer (read implementer), I don't really care where it goes.. so long as the data is saved and able to be retrieved later
 

« first day (648 days earlier)      last day (4300 days later) »