-
Posts
15,289 -
Joined
-
Last visited
-
Days Won
436
Everything posted by requinix
-
Oh right, it's a jQuery object. console.log(button2[0]) Or expand/click on the element it logged. Is it the right one? Sally Lawrence?
-
I'm not sure why you're doing it that way... What if you literally console.log(button2)?
-
And if you console.log(button2) as well?
-
Time to learn! There's a bit in there where it takes the value entered by the user and compares it to the correct answer. Use strtolower (check the examples on the page kicken linked) to get a lowercased version of the user's answer, and compare that result to the correct answer.
-
I guess I'm not really sure where the difficulty is? You have the HTML that puts the video on the page, and you have the HTML (containing Javascript) to set up the video. You put them together. Do you know what the resulting HTML is supposed to look like? If you know that then it shouldn't take much to see where the <script>s need to go.
-
How does PHP determine to create a new copy of a copied array?
requinix replied to NotionCommotion's topic in PHP Coding Help
You only changed a 529KB/11MB portion of it. PHP doesn't need to create a whole new damn array if you change something in the middle of it... I can't tell if you're saying it added 11MB or did not drop 11MB. Ditto. Also, stop calling it a reference. It is not a reference. -
loop through array with incremental for striped table
requinix replied to Wal-Wal-2's topic in PHP Coding Help
FYI, this can be (and should be) handled entirely with CSS using nth-child(), not(), and first-child. -
var_dump of an array shows just one variable
requinix replied to makamo66's topic in PHP Coding Help
Exactly what does it show? -
Sure looks like HTML to me. The "phtml" just means it's HTML that has some PHP in it. What code?
-
I don't see anything that even indicates there's a problem... What do you see in the browser? Some text is going red?
-
How does PHP determine to create a new copy of a copied array?
requinix replied to NotionCommotion's topic in PHP Coding Help
Don't think about it in terms of references. Those are really just about &s. What PHP does with everything, not just arrays, is called copy-on-write. Meaning PHP will reuse a value up until you try to change it. That is when it starts making a copy. That's why they say never to use references to save memory: PHP is already saving memory for you. -
You adjusted the php.ini. Did you adjust all the required settings? There's a few. How about settings with the web server software (eg, Apache or nginx) itself? Are you being limited there. Saying it didn't "go through" doesn't mean a whole lot, technically speaking. Is there an error code in $_FILES? Do you get an error page from PHP or the server? Can you see the browser uploading the file and then stop at some point before it was able to upload everything?
-
Wouldn't it be easier to just post the problem and see what happens?
-
There really ought to be a good, clean CSS answer to this.
-
The error is complaining about a comma in the code. There is no comma in that code.
-
Well, all I can really do is tell you about the problems you post here, and this current one is because you're typing two apostrophes in the place of one quotation mark. If you still have problems after fixing that then we'll deal with them. But you'll have to describe them.
-
I take it you've seen " before but never typed it out until now? That there is (supposed to be) a double quote, not two single quotes. Shift + '
-
PHP mail function how to set sender mail id based on if condition?
requinix replied to aveeva's topic in PHP Coding Help
Oh, I saw a thread about that a second ago... Here. That looks like it talks about your question exactly. -
You're running MySQL and only have 1GB in use out of 32? Increase that now, then watch how the server behaves.
-
Oh damn, I didn't even see this thread when it was first created. Yeah, I don't know what happened. Nobody changed anything. Couple days ago I applied the latest IPB patch and the problem went away. I suspect it was some sort of template caching problem.
-
Need help on getting products to insert into database
requinix replied to purge08's topic in PHP Coding Help
That's a whole lot of code to have to read through without having any idea of what to look for - "having an issue" really doesn't say much... -
Traits or inheritance for reducing duplicated code?
requinix replied to NotionCommotion's topic in PHP Coding Help
It is true, traits cannot be hinted - they are designed to be, and really do work very much like, language-assisted copy and paste. -
If not, then you can't use that approach of the root interface having two arguments and child interfaces for pie and time charts having their own interfaces with three arguments. Eh, the only thing I have is to create a sort of ExtraChartDataThing class, then you have methods for the pie and time charts to add data to it, then those classes can pull the data back out when they want it. And if there is no data they throw up. Or slight variation, maybe better, it's still a key/value store, but the key is a class name (thus unique) and the value an instance of it, then you stuff your Parameter/TimeOffset data into without needing special chart methods.
-
Traits or inheritance for reducing duplicated code?
requinix replied to NotionCommotion's topic in PHP Coding Help
Traits are copy and paste. If there is any meaning to the code besides you wanting to simply save yourself some copying and pasting then a trait is not the right answer. -
Obligatory "welcome to the world of software development". Things change. Try to anticipate and plan for what might happen, but otherwise you're kinda stuck just responding to changing business needs. Saying that everything gets an optional data structure of "stuff" makes sense. Not all chart types may need it, but a general purpose "stuff" thing doesn't sound unreasonable to me. It could only work if the pie and time charts could come up with some sort of reasonable default behavior. If not, then...