-
Posts
15,274 -
Joined
-
Last visited
-
Days Won
432
Everything posted by requinix
-
/** QUERY THE DATABASE FOR AN ENTRY FOR THIS DAY !! IF MATCHES FOUND, PRINT THEM !! **/ $sql = "SELECT * FROM $tablename WHERE $current_epoch BETWEEN $start_day AND $end_day"; /** NEED TOQUERY THE DATABASE FOR AN ENTRY FOR THIS DAY !! IF MATCHES FOUND, PRINT THEM !! If you have code outside the function that is capable of querying the database then it should be a fairly simple matter of moving that code into the function. Note that running the query requires having the $conn variable, so you'll need to pass that into the function as another argument to be able to use it. It also requires those two variables in there, which currently aren't being set.
-
Yeah, no. It just means you have to define a $htmlTitle variable in the code before it includes html_head.php.
-
Rewriting index.php and news-index.php
requinix replied to SaranacLake's topic in Apache HTTP Server
Use index.php for all three of them. -
Forget the menutitle. Forget it. Look at the CSS rules being applied to the heading. Two of them involve text-transform.
-
This has nothing to do with .menutitle. Are you familiar with your browser's developer tools? If not then you really need to spend some time learning about them. Open your developer tools, find the menu, and consider applying the mHover class manually to force it open. Then navigate (in the tool) to the heading's A or SPAN and look at what CSS rules are being applied. I see three rules whose selectors all have a > chain that targets the link. Two of those have text-transforms.
-
Putting put string text in javascript raise syntax error
requinix replied to mstdmstd's topic in PHP Coding Help
Normal Javascript strings do not work across multiple lines. If you're putting a value into Javascript then use @json instead. You should basically never ever use {!! for anything. -
I see one "text-transform: uppercase !important" and another "capitalize" (not !important). So obviously the !important one will override. Throwing !important on the second won't fix it because all you've done is make them of equal specificity, so the one defined later wins. Seems like you've got a lot of duplicate rules and a lot of !importants in there. Both of those are indications of problems with the CSS. Look through what you've got, cut out as much as you can without severely breaking everything, and try giving it all another shot.
-
That code will never add the WHERE to the query. What's your actual code?
-
PHP https with $_SESSION send to another page
requinix replied to nitiphone2021's topic in PHP Coding Help
Looks alright. Is that the same information you see on the first page (which sets a session value) and the second page (which is unable to get the value back out)? -
PHP https with $_SESSION send to another page
requinix replied to nitiphone2021's topic in PHP Coding Help
But are you doing that for every place that calls session_start()? It's still better to configure the session cookie in your php.ini, not in code. Never have to think about it if it's configured there. There's more to a cookie than just its expiration. What are the details of the cookie as seen by your browser? I'm talking like domain, path, and flags. -
Yes. The content and structure of the page matters far more than its URL.
-
Urban myth. Google does not care. People care. People like it when they see a picture of a dinosaur and there's the word "dinosaur" somewhere in that magic box on top of the screen where they type stuff and Google searches for it.
-
Yeah. And I'm saying don't do that. It doesn't work. It's incorrect.
-
{ query: encodeURI(url) } That is the place that lists out the values to pass. You are only passing one because you crammed the query+c+country into the value. Keep the "query" being the query and add a "c" for the country.
-
[PHP 7.4.13 ] imge uppload to database using PDO::
requinix replied to Sprint666l's topic in PHP Coding Help
Unfortunately my crystal ball has exploded so I can't use my supernatural powers to instantly know everything there is to know about your application and code. So we'll have to do this the hard way by having you use your fingers and keyboard to type out the kind of information that is important for someone like me to have if I'm to tell you where the problem is. The "File upload failed" message means your INSERT query failed. Why did it fail? To find that out, try using PDO::errorInfo. -
[PHP 7.4.13 ] imge uppload to database using PDO::
requinix replied to Sprint666l's topic in PHP Coding Help
You cannot use anything in $_FILES until after you've tested to make sure there's something there to use. In other words, you can only set and use $fileName inside that main if block. -
PHP https with $_SESSION send to another page
requinix replied to nitiphone2021's topic in PHP Coding Help
Browse around your site and make sure the browser always says the page is encrypted, or at least it never says it isn't encrypted. With Chrome, for example, a padlock icon on the left of the address bar means it's HTTPS. -
PHP https with $_SESSION send to another page
requinix replied to nitiphone2021's topic in PHP Coding Help
Make sure every page on your website is being served over HTTPS. Also check your session cookie settings. -
How can I save and publish my changes in codepen.io item ?
requinix replied to mstdmstd's topic in Miscellaneous
1. Open a new tab or window with a new pen 2. Copy the HTML 3. Copy the CSS 4. Copy the JS 5. Save -
Don't layer the background behind the foreground. Layer the foreground on top of the background. Take a DIV of whatever size you want and position it on the page wherever you want the container of all this to be. position: relative but that's basically it. Then add your background images to it. position: absolute and left/top and/or right/bottom however you need. Do a bit of math on the backend to figure it out (or hardcode it, as the case may be). Then add the foreground image. position: absolute so it appears where you want. You shouldn't have to z-index it or anything else. Example It's a bit more hands-on with the positioning than I would like; some fancy CSS might be able to fix that.
-
Are the images supposed to go "behind" the main table/form/image, or do they flow around it? Can you put this in a jsfiddle or similar?
-
About z-index, if you want images to the right overlapping images to the left (ie, in document order) then you don't have to worry about z-indexes. Still not sure what the problem is. Making them overlap is one thing, but beyond that it just sounds like you're talking about having multiple images inline with each other. And that doesn't require doing anything more than having multiple images without using line breaks or wrapping. As in <div> <img ...> <img ...> <img ...> <img ...> </div> What you might not be mentioning is that you want certain images on each line. Or a certain quantity of images. In other words, something that depends on knowing the width of the screen...
-
Well... the most obvious answer to "I want a bunch of images on the same line and then repeated for multiple lines" would be to put the images (as inline or inline-block) inside a block DIV for each line. How about a more thorough description of what you're trying to do? Possibly with screenshots or some rudimentary diagrams?