« first day (719 days earlier)      last day (4213 days later) » 

hey guys..... any problem?? maybe i can help.. ;)
im only here for five minutes.. ;)
 
@Gordon wait... imma try
 
8:18 AM
@GeraldStojakovic you only have 31 reputation so you cannot cv yet but thanks ;)
 
dont underestimate me dude ;)) lolz ;P
@Gordon dude... i have post my answer regarding your problem hope it helps :)
just buzz me if you have any question ;)
 
@GeraldStojakovic problem? what problem? I didn't ask a question. I asked the linked questions to be closed
0
A: Wrong parameter count for number_format()

Gerald Stojakovici think you dont have any error, just put this line of code at the first line error_reporting(0); this will disable any error you occur,

that answer is wrong.
 
@Gordon No it isn't. the best way to handle all errors is to stick your fingers in your ears and shout "lalalalala" as loud as you can.
 
What the others answered is correct. number_format does not accept three arguments. Also, suggesting to disable error reporting when there clearly IS an error will help nothing. The error wont magically go away. Also, in a development environment you want error reporting to be enabled.
@DaveRandom obviously ;)
 
8:32 AM
...and morning all
 
good morning
and the question is closed btw. It's also a shame who is stepping in to actually answer that. - del voting now.
 
@DaveRandom I thought that was what the @ operator was for?
 
@vascowhite the @ operator is to hide some errors as long as you're using PHP's logging. A concept I never fully understood.
 
@hakre +1
 
@hakre Sorry, I forgot to put <sarcasm> tags around that :)
too early for humour?
 
8:36 AM
@vascowhite no, not at all. I'm not on full energy anyway, have a cold.
 
@vascowhite that is no laughing matter -.-
 
@Gordon True, true, but I have a bit of a sick sense of humour, sorry about that :)
 
@vascowhite actually i was joking. go ahead
 
Good morrow chaps
 
morning
 
8:43 AM
@PeeHaa Example URL? (I'm not sure what you mean - /review pages seem to just link to /questions pages) - although I spotted a couple of minor issues last night that will need to be fixed before release, so expanding the scope could be included as well. I also saw you post a delv-pls on an answer a couple of days ago which was not picked up, and again this should be fairly easy to account for.
@vascowhite No that's just for double safety. The first line of your script should always be @error_reporting(0);
@hakre What kind of a girly excuse is that? Any more like that and I will revoke your real-man status :-P
 
@DaveRandom oh, you have not revoked it already. I think this friday we should do another gender-switch friday.
 
Say, do you guys know if there's a significant performance hit for excessive output to STDOUT when not attached to anything (ie, output discarded)?
 
no clue, you need to test that I can imagine it has differences based on the I/O subsystem.
 
9:00 AM
@hakre I'm not much familiar with the concepts involved, but I suppose that would depend on the OS more than anything else, correct?
 
Yes can depend on OS / system libraries.
what is your case? in which kind is STDOUT not attached?
 
@hakre Quick example: running chkdsk in terminal causes its output to be passed over to the terminal. If chkdsk is run directly (CreateProcess) with no terminal/console, STDOUT will be discarded (I think?)
@hakre I'm not writing code for this, nor anything related....just curiosity...
 
it might be discarded, but there still might be a pipe. check msdn .
 
'k
 
@hakre Handles still exist even if you don't AllocConsole, the handles are set to the consoles input/output buffers when it is allocated
Pretty sure you can write to STDOUT without a console
 
9:14 AM
isn't there some /dev/null you could point to?
I remember in DOS there was.
 
What are you actually trying to do?
Writing to a disconnected stdout is faster than writing to a connected one
not writing at all is even faster
 
Well, my thought was on the lines of:
- if I run test.exe through cmd to see its output, it will probably be slow - but that's ok, since I'm not that fast at reading the text anyway (ofc there's `less` etc)
- however, I want that test.exe runs at full speed when not run from cmd, therefor I just run it without a console.
I'm trying to straighten that out, ensuring my reasoning is correct as well as get some extra knowledge on the way.
 
You're using winapi?
 
By the way, just realized there's a feature in PHP that JS doesn't have (by design): expression in hash keys short notation:

$a = array('a'.$b => 'c');
var a = {'a'+b: c}; // syntax fail
16 mins ago, by Christian
@hakre I'm not writing code for this, nor anything related....just curiosity...
 
@Christian Well, like I said, writing to stdout when it's not attached to a console output buffer will be faster than when it is attached, the output will be silently discarded. You could go one further and wrap your writing function and at the start of your program call GetConsoleWindow and store the returned HWND. Short circuit the write if the console window doesn't exist.
 
9:27 AM
@Leigh Guess that ensures you don't write to the console buffer even.
 
If there is no console window, there is no buffer
 
need a Rich Text Editor(js) support image and video any idea
 
@Leigh So the program doesn't even buffer it....interesting.
@raghulrnair You can't do that in PHP. Sorry.
 
@Christian ok try in js
 
@raghulrnair They'll tell you to write it yourself. And that all javascript libraries suck.
 
9:30 AM
@Christian It discards it if there is no buffer to place it in. The buffer could be a console output buffer, it could be a named pipe, it could be a file.
 
@Leigh Well, I was thinking... doing $hout = null; fwrite($hout, 'stuff'); would cause a runtime error, so if the program was written correctly, it would avoid the fwrite() call by design.
 
6
A: Detect if a PHP script is being run interactively or not

LeighI also needed a slightly more flexible solution than posix_isatty that could detect: Is the script being run from the terminal Is the script receiving data via a pipe or from a file Is the output being redirected to a file After a bit of experimenting and digging around through libc headers, ...

No idea how it works on windows
 
how can i include Rich Text Editor in my page ? and any useful link u hav?
 
@raghulrnair Just search for javascript wysiwyg
 
if it does work on windows, you could just make your own writeOut function and avoid calling fwrite at all under certain conditions, if you notice a performance hit.
 
9:35 AM
@Leigh That code, sir, is great.
 
@Christian need to include in my php page
@Christian like a tex area
 
@Leigh If you don't mind, I'm throwing that in the next framework I'll possibly be writing.
 
Frameworks frameworks everywhere, but not a .. something to something ...
 
@raghulrnair That link showed 25 different wysiwygs, some of them are bound to have a PHP example.
Even if not, it's easy to do it.
 
Wow, been ages since I heard someone say "water water everywhere, but not a drop to drink".. why did that come into my head :x
 
9:41 AM
@Christian thks man
 
@Leigh Sounds like someone describing the sea...
 
Mhm
The Rime of the Ancient Mariner (originally The Rime of the Ancyent Marinere) is the longest major poem by the English poet Samuel Taylor Coleridge, written in 1797–98 and published in 1798 in the first edition of Lyrical Ballads. Modern editions use a later revised version printed in 1817 that featured a gloss. Along with other poems in Lyrical Ballads, it was a signal shift to modern poetry and the beginning of British Romantic literature. Plot summary The Rime of the Ancient Mariner relates the experiences of a sailor who has returned from a long sea voyage. The Mariner stops a ma...
 
@Leigh Oh. I hate poetry. :D
 
Old poetry > new poetry in 99.99% of cases.
 
@Leigh I don't think I've ever had a chance to see the difference.
 
i think redactorj is best one redactorjs.com
 
@Gordon OMG. 10 answers already.
 
Lets all jump on the rep train!
 
@Christian No more.
 
Closed Qs get auto deleted after a period right?
 
@Leigh Hope so. Can't see them storing terabytes of closed question with that kind of quality.
 
I'm having a hard time to install the cv-pls on chrome Version 22.0.1229.79 over here on fedora 17.
 
@Leigh Not if they have upvoted answers.
 
it looks like that if drag and drop does not work.
 
9:55 AM
@hakre Wait, Chrome works on Fedora? :D
 
@hakre Have you tried simply running the user.js script?
Oh, my bad, it's an extension not a userscript.
@hakre Google has disabled external extension sources (outside of their Chrome Market)
"Open source" my ass
You need to download it, enable development environment, and install it manually.
 
@MadaraUchiha Right, need to get my rep-whore on again it seems.
 
I don't get it
Why do everyone want to have a wrapper class around PDO?!
PDO is the freaking wrapper class!
 
@MadaraUchiha You still need to run queries though.
 
@Christian So freaking what?! That's SQL for you
Big bad queries
I've never seen anyone asking for a mysql_* wrapper classs
 
9:59 AM
@TimPost I'd like to add my answer stackoverflow.com/a/12435641/208809 to stackoverflow.com/a/3577662/208809 but I think the latter will turn CW when I edit it. Would you uncw it for me if I did?
 
@MadaraUchiha Asking? Well, I did have such a class, fts.
 
@MadaraUchiha to turn it into a Singleton :D
3
 
What's CW?
 
@Gordon +
 
@Gordon So, sadly true.
 
10:00 AM
@Leigh community wiki
 
@Leigh Community Wiki
a.k.a. does not generate reputation from upvotes :D
 
Of course it is.. derp derp
 
@Leigh Cheese Wheels. Don't listen to the other guys.
 
@Christian blasphemy, cheese should only eaten, not used to make mechanical parts!
 
any one using yii ?
 
10:04 AM
Nope... But I'd sure like to use the Wii though :D
 
@ShyamK www.yiiframework.com
 
lol, despite one delv is missing, heres some fun: stackoverflow.com/a/12722342/367456
 
which is best framework in php
 
user1125394
phpQuery
 
10:08 AM
@raghulrnair windows 8
 
@Gordon why?
@raghulrnair best framework is one you know how to use.
if you don't know any yet, start with a new one. currently Zend Framework 2 is on top.
 
Good Morning
 
Aloha
 
good morning.
 
@hakre google result says yii is best
 
10:11 AM
@raghulrnair well google is not really that into php frameworks lately. but you're right I should have asked oracle-g first before placing some answer here.
 
@raghulrnair Yes, Google knows best. Why don't you ask Google to write all of your code for you.
I wonder... if we could make something that trawled random snippets from google and made a random script out of them...
 
yii write CRUD code for u man phpframeworks.com
 
@hakre because it keeps getting upvotes and it can be solved with css
 
we could call it: goo-goo-phpunky !
 
10:13 AM
If ircmaxell joins the chat and does not post a twitter first (or some other link), chances are high you see a or next. :)
 
hi :P
 
lol
 
Otherwise you see the tags after the link.
 
@hakre am just bignr php and yii
 
SELECT FName from tablename
 
10:15 AM
@raghulrnair you should add some IPv6 and regex to power up to next level.
 
I want to show FName starting with 'A'
 
@Gordon you got my vote. still 4 others left (now 3).
 
die(mysql_error()) gives PHP a bad reputation stackoverflow.com/questions/12724613/problems-with-sql-command
 
@hakre i dot get
 
10:17 AM
TBH, it seemed like a good question...don't know why it was closed.
 
@raghulrnair come back when you've reached the next level. Google will tell me if that is the case.
 
@MrCode No, idiots give PHP a bad reputation by perpetuating their idiocy, continuing to write new code using mysql_* functions for example.
 
Gotcha SELECT FName from mst_authors WHERE FName LIKE 'A%'
 
@hakre sorry man
 
http://stackoverflow.com/questions/12724613/problems-with-sql-command
 
10:19 AM
@raghulrnair Google will also tell if it is time for excuses.
 
@hakre k
 
@DextOr What's your question? Your SQL looks correct.
 
@hakre which s ur fev framwk ?
 
@raghulrnair You first need to reach the next level before I will answer your next question.
And beware with any further ping your avatar will shrink in size.
but maybe you can create me a screencast how I can add the cv-pls extension on a fedora 17 box to current google chrome?
 
10:33 AM
Suggested SO mod if(strpos($answer->content, 'or die(mysql_error())') !== false){ $answer->append("\n\n Don't use this."); }
 
10:53 AM
@Gordon you are really nice. I tend to just close without any further comments those questions that start with "I searched whole day / whole internet" and so on.
It's often a smell of an introduction for a trivial question.
 
mornings
 
Is it just me, or is this question a complete logical failure, but now protected by a bounty? stackoverflow.com/questions/12598383/…
 
@raghulrnair why did you link tho that ancient and misguided site ? It says that Symfony's latest version is 1.0.9 (that's late 2007th)
@raghulrnair also , what google results , where ?
 
@hakre I close a lot of Qs without a comment :)
 
Hi, do any one know why my article node, in drupal , is not showing the form inside that article?
actually, my article has an html code <from></form> which is not getting displayed
 
@Leigh Really? Why it takes my program a different number of nanoseconds to run?
 
@Varada you are likely doing something wrong
 
@MadaraUchiha Your clock is not 4D (pdf), leading to inaccuracies
 
@Leigh Thanks for the replay, in node when I print print_r($content); exit;
I can see the form but when executes the code print render($content); it is not displaying
 
11:06 AM
What? Avatar, shrunken
 
@Gordon Thanks for the replay, in node when I print print_r($content); exit;
I can see the form but when executes the code print render($content); it is not displaying
 
@Varada Is it there in the source code?
 
no, It is not
 
@Leigh True, might be. But let's just let it time out so that OP wasted the bounty and we then close and delvote it. Only a day or so left.
 
11:07 AM
And crap, I just found a better duplicate than the one I used to close a question. Do we maintain a list of canonicals anywhere?
 
I can see it when I print the object in my node.tpl.php
 
@Leigh We deffo should.
 
@Leigh start with a gist or so. there are some lists.
 
1066
Q: The Definitive Guide To Forms based Website Authentication

Michiel de MareForm Based Authentication For Websites Please help us create the definitive resource for this topic. We believe that Stack Overflow should not just be a resource for very specific technical questions, but also for general guidelines on how to solve variations on common problems. "Form Based...

This should be on it
 
11:07 AM
@Leigh I just love the incredible avatar shrinking ray! It's my favourite special power.
 
@Leigh nope, i once suggested to introduce something like a canonical tag on meta but it didnt get much attention
6
Q: Introduce a Canonical Question tag

GordonHow about introducing canonical-question to StackOverflow in order to make it easier to identify them? The general idea is to have either moderators designate individual canonicals and/or auto tag those questions which have been given most often as a possible duplicate. This would allow us to l...

 
Woot, 12 hours until my flight to Europe!
 
You're excited about spending 10+ hours on a plane.. Your days must generally suck :p
 
No, I'm excited about after the 9 hours...
 
I'm writing a time interval on a site using javascript with millisecond's difference. I need to pad this time with 0 so that it ends up with two digits after decimal point. Something like PHP's str_pad().
 
11:09 AM
@ircmaxell How long are you staying for?
And visiting any other countries?
 
In the UK: until Monday
 
@ircmaxell you gotta hurry to the airport. I hear it takes ages until everyone got their enhanced freedom pat and shampoo checked
 
Now, I know there are countless ways to do this, but because of my use case, it needs to be as performant as possible.
 
then 7 days in northern Italy, 5 days in France (Paris), 2 days in Amsterdam, 1 day in Manchester, and then fly home
 
"please don't vote down this post"; For some reason, that always makes me click that down arrow!
 
11:10 AM
@Gordon Yup, it does
 
@ircmaxell UK isn't Europe. They don't have the Euro and they don't use the Metric system
 
@Gordon Sure it is...
 
No we're not!
 
@ircmaxell You're visiting Europe and not visiting Malta?!!? Shame on you!!
 
Ok we are, but we shouldn't be
 
11:11 AM
lol
 
see ^^
 
It's surprising we are, part of joining the EU is signing some sort of open borders treaty, but the UK didn't sign it.
 
Schengen Agreement...
 
The Schengen Agreement is a treaty signed on 14 June 1985 near the town of Schengen in Luxembourg, between five of the ten member states of the European Economic Community. It was supplemented by the Convention implementing the Schengen Agreement five years later. Together these treaties created Europe's borderless Schengen Area, which operates very much like a single state for international travel with external border controls for travellers travelling in and out of the area, but with no internal border controls. The Schengen Agreements and the rules adopted under them were, for the EU ...
yea was just looking for it ;)
 
@vascowhite Where?!
 
@MadaraUchiha here
 
@tereško please don't use tags like that. It's caused us problems in the past
 
fixed that
 
@tereško can simply delv the Q
 
@tereško Much better! Thanks!
 
11:16 AM
@Gordon of course , but since it is a fresh question, framework advertisers might get a short-term-scare
 
@Gordon If you [tag : canonical] as a comment, does it become searchable?
 
@Leigh It does, but it'll likely to be burned very fast.
 
you can search "cannonical" but that's about it oh , i thought you meant it in chat
 
Hm, was looking for a workaround to avoid actually placing meta-tags on the questions themselves
 
11:18 AM
@Leigh what @MadaraUchiha said
 
I guess a gist is the best way to go
 
@Leigh I could add parsing for in the CV Backlog crawler though
 
Volume RAID 5 Disk Volume: Drive 1 2 3 4
Total Size 2059.78 GB
Free Size 1027.48 GB
Status Rebuilding...(93%)
 
You didn't go for the $10k set-up then ;)
 
no
not yet anyway
 
11:24 AM
I'd much rather an independant site which would hold all of these questions, and a short description on which questions it should be used, perhaps.
 
morning
@tereško yeees, and removing spaces...
 
@tereško maybe this will interest you
9
Q: How can one describe a rock-paper-scissors relationship between 3 items?

Madara UchihaLet's say I have the following structure: abstract class Hand {} class Rock extends Hand {} class Paper extends Hand {} class Scissors extends Hand {} The goal is to make a function (or a method) Hand::compareHands(Hand $hand1, Hand $hand2), which would return the winning hand in a rock-paper...

 
stackoverflow.com/questions/12719650/… ("discuss my code/idea" post)
@MadaraUchiha actually i was disappointed
 
11:44 AM
Off to work
later all...
 
@MadaraUchiha How about...
abstract class Hand
{
	public $beats;

	public function beats(Hand $opponent)
	{
		return $opponent instanceof $this->beats;
	}
}

class Rock extends Hand
{
	public $beats = 'Scissors';
}

class Paper extends Hand
{
	public $beats = 'Rock';
}

class Scissors extends Hand
{
	public $beats = 'Paper';
}

$r = new Rock;
$p = new Paper;
$s = new Scissors;

var_dump($r->beats($p), $r->beats($s));
 
12:02 PM
i'm kinda tempted to flag it
 
@tereško What exactly? The question?
 
you previous line ... it kinda falls under "plagiarism"
 
@tereško Of what exactly?
 
lol, just comming to chat and see that ! :)
however I strongly suggest to use protected not public member for that.
your function and parameter naming is better though
 
Well your answer wasn't there when I started writing
so it's not plagiarism, it's confirmation that your answer is correct
 
12:06 PM
I believe you, it's just the coincidence that makes it funny.
@Leigh I will plagiarize yours now a little ;)
 
that's fine, the question should be closed not constructive anyway
 
@MadaraUchiha what I dont like about the solutions so far is, that the subtypes have to know about the other subtypes. IMO, what beats what should not be in them. It's config data.
 
Time for ?
 
@Gordon Yes, that's what is bothering me too. And we already discussed that yesterday, let me find the transcript...
 
interface IConfigurableHand....
 
12:15 PM
 
@NikiC yupp, I'd likely have some sort of EvaluateHand strategy which knows the rules of the game instead.
 
@Gordon Not so really. It's only that one concrete type needs about another one. However, you could put that knowledge into interfaces first.
 
@hakre the concrete type having to know about other concrete types is exactly what I dont like about the solution. Interfaces won't help. This will get quickly out of hand (no pun intended)
 
@Gordon Yes I know, that gets out of hand ;) Done that one, complete mess. However in this three case scenario and the template method pattern, I don't think this problem is near.
 
Why do you guys always have to take something simple and apply a ton of bullshit to overcomplicate it :/ - It's rock paper scissors.
 
12:20 PM
class EvaluateHands
{
    private $rules;

    public function __construct(array $rules)
    {
        $this->rules = $rules;
    }

    public function compareHands(Hand $hand1, Hand $hand2)
    {
        return $this->rules[get_class($hand1)] === get_class($hand2) ? $hand1 : $hand2;
    }
}
new EvaluateHands(
    array(
        'Rock' => 'Scissors',
        'Paper' => 'Rock',
        'Scissor' => 'Paper'
    )
);
untested, but something along the lines of this would probably work and seems easy and clean enough
 
this is pretty much the second suggestion in Lusitanian's answer.
and might carry the simplicity @Leigh strives for
 
hi all, I have to post a value via form post and insert it into table, here is my html: <input type=hidden id="category" value=" <?php echo $cat_no; ?> "> but it sends this value \". $cat_no .\"
 
@hakre I'm just of the opinion that, there's no point making something more complicated than absolutely necessary.
 
well, of course you can make the Hand subtypes configurable and accept which hands they beat
 
@Muhammad Looks like your file is not being processed by PHP.
 
12:29 PM
You could do it without the subtypes and just have it accept the hand it beats in the constructor, and then $rock = new Hand('Scissors')
which looks incredibly counter-intuitive
although then you wouldn't know the type of hand being passed to the beats method, but whatever
I think this question has had enough attention ;)
 
@Leigh the only drawback of that is that you depend on strings. not that much of an issue imo
 
@Leigh which is a very good and important point.
but often hardest to achieve.
 
@Gordon as does your configuration array in your EvaluateHands class.
 
@Leigh true. should change it to
new EvaluateHands(
    array(
        new Rock => new Scissors(),
        new Paper => new Rock,
        new Scissor => new Paper
    )
);
 
@Leigh In the original function implementation, there were done some constants for the hands.
 
12:32 PM
using objects as an index?
 
@Leigh with __toString this might work ;)
 
@Leigh yeah, well, that was just a quick search and replace. of course, you'd either use spl_object_hash or an splObjectStorage if you wanted objects for keys
 
Which could be done in abstract base class gg. so far for simple.
I think it's okay to outline the patterns.
I added the EvaluateHands class to the answer btw @gordon
 
@hakre heh, stealing my answer :P
 
@Gordon the complete answer is stolen. From: a) Lusitanian b) Leigh c) Gordon.
 
12:38 PM
Morning folks
 
heya!
 
I'm trying to mock against a class that calls curl directly. I have the following, but calling the mock method always returns null. Can someone point me to what I'm doing wrong?

$mockApi = $this->getMockBuilder('ContactologyAPI')
				->disableOriginalConstructor()
				->setMethods(array('Contact_Add_Email'))
				->getMock();
$mockApi->expects($this->at(0))
		->method('Contact_Add_Email')
		->with($this->equalTo($email))
		->will($this->returnValue($expectedData));
 
Quick question of terminology; when dealing with the filesystem, treating directories/files as nodes; the contents of a directory would be children, and recursive children would be ... recursiveChildren, descendants?
 
@gms8994 ZF indentation :(
 
@Gordon actually, the -> lines are supposed to be lined up with the first one. my copy and paste failed
 
12:41 PM
@gms8994 that wouldnt be easier on my eyes ;)
 
do you prefer all on one line?
 
$mockApi
    ->expects($this->at(0))
    ->method('Contact_Add_Email')
    ->with($this->equalTo($email))
    ->will($this->returnValue($expectedData));
is how I usually do it
 
ah. interesting
 
Same; +1 indent for multi-line statement continuation.
 
anyway, thoughts on why it's returning null, and not $expectedData?
 
12:42 PM
$mockApi
    ->expects($this->at(0))
    ->method('Contact_Add_Email')
    ->with($this->equalTo($email))
    ->will($this->returnValue($expectedData))
    ;
 
$mockApi = $this->getMockBuilder('ContactologyAPI')
    ->disableOriginalConstructor()
    ->setMethods(array('Contact_Add_Email'))
    ->getMock();
 
@hakre no indentation at all?
ah
 
@gms8994 fixed, see end of statment.
that however does not work well with codecoverage ;)
 
@hakre got it
 
ah and since you had tabs and they messed up the paste, let's get back to our discussion from two days ago. quoting @NikiC
yesterday, by NikiC
God, people, just shut the fuck up and use 4 spaces
:D
 
12:44 PM
I care less about indentation than I do working code ;)
so
 
@Bracketworks sounds both equally fine to me
 
@Gordon yeah life can be simple again :)
 
any idea why calling $mockApi->Contact_Add_Email($email) doesn't return $expectedData, but instead returns null?
 
maybe function returns void? - ah mock...
 
@gms8994 have you tried with $this->once() instead of $this->at(0) and have you made sure $expectedData contains not null
 
12:45 PM
@hakre it's a mock. I've told it what to return
@Gordon yes; same result, $expectedData = true;
 
what happens when you remove ->setMethods(array('Contact_Add_Email'))
 
but $testData comes back as null
same
 
@cspray I debug / echo the posted values and it print \". $cat_no .\"
 
@gms8994 then I really dont know. sorry
 
let me pastebin everything that I have
 
12:49 PM
@Muhammad more interesting is the HTML first. how does it look like when you make "view source" in your browser?
 
pastebin.ca/2239316 -- my test file
pastebin.ca/2239319 -- the class I want to test
 
@hakre let me check
@hakre its same \". $cat_no .\"
 
@gms8994 not that familiar with mocks, but maybe you need to set return value independent to input expectations.
@Muhammad so fix your HTML first.
 
@hakre nope, that should work
 
@hakre sadly, I tried that as well, by commenting line 24. makes no difference
 
12:53 PM
@hakre where am I wrong?
 
public static function Contact_Add_Email(
$testData = $mockApi->Contact_Add_Email($email);
you probably need a static mock for that
 
@Muhammad You're perfectly fine. Contact your hosting support and ask them where to enable PHP.
 
8
A: PHPUnit Mock Objects and Static Methods

GordonSebastian Bergmann, the author of PHPUnit, recently had a blog post about Stubbing and Mocking Static Methods. With PHPUnit 3.5 and PHP 5.3 as well as consistent use of late static binding, you can do $class::staticExpects($this->any()) ->method('helper') ->will($this->re...

 
@Gordon that's it! I actually added that static when I tested something else previously. removing that fixes the issue
Gordon++
 
@hakre my php is enabled and working well.
 
12:55 PM
yay! I am awesome! ;)
4
 
I'd completely forgotten about that
thanks a bunch!
 
np
 
cool!
 
Gordon, when you get incremented, what actually happens? Taller? Wider? A clone of you is produced?
 
what? no stars for i'm awesome? come on …
better :)
@Leigh im not sure. I didnt feel a thing
 
12:57 PM
now, do you know if that will count for CodeCoverage?
@Leigh he just becomes Gordon + 1
 
morning
 
+1 what :/
 
if only SO considered that for reputation purposes ;)
 
@DaveRandom http://stackoverflow.com/review-beta/close/747250
Anybody ever tried to work with Zend Studio's Git integration?
 
speaking of review beta. is there any way we can modify our cv process so it links the cv-pls links to review? we dont get anything for closing here :/
 

« first day (719 days earlier)      last day (4213 days later) »