-
Posts
15,227 -
Joined
-
Last visited
-
Days Won
427
Everything posted by requinix
-
It'll be hard to tell you what you've done wrong without a description of what's happening...
-
What is your code, what output do you expect to see, and what output do you actually see?
-
URL rewriting has nothing to do with CORS. What error are you getting? Are you using different domains for some files?
-
When you do stuff with SimpleXML, by default it starts in the "" namespace. But your XML doesn't use the "" namespace. It uses the "http://www.finavia.fi/FlightsService.xsd" namespace. Set up that namespace with XPath using registerXPathNamespace(), then try querying it with a namespace prefix. // prefix can be anything, xmlns URL is what matters $xml->registerXPathNamespace('f', 'http://www.finavia.fi/FlightsService.xsd'); // names need an f: prefix $otsikot = $xml->xpath('//f:flight[f:fltnr="AY456"]/f:acreg');
-
So you want the user to see "Volvo" as the option, but have something in there that shows "Car choices" alongside it? Use an optgroup, then add some Javascript to copy the selected option's parent optgroup label to some other element that's useful. Or go with a fancy dropdown element/library.
-
how to hide data behind the = (page.php?id=xx) for the user
requinix replied to wildware's topic in PHP Coding Help
...with the unfortunate downside that a user can simply add an ?id to bypass the "verification" this process tries to add. Side note: adding arbitrary data into the session is generally not a good idea. -
how to hide data behind the = (page.php?id=xx) for the user
requinix replied to wildware's topic in PHP Coding Help
Assuming that the user ID is not supposed to be for the current user, If ranklist.php needs to know which user ID to show then there is no way to hide that information from the user. If you don't want to show the information then make ranklist.php decide whether or not to show the information. It should check the current user, decide if they're "allowed" to see other users, and if not then give an error or redirect away or something. -
What is your code for this site? It's not behaving correctly, and I suspect you're using session variables for something that shouldn't be using session variables. What I see is that the first visit to your site redirects me to /?i=1 and the home page, then I click About and go to /index.php?page=about, then when I try to go to / (or /index.php) I continue getting the about page. That happens for the last page I visit, whichever page that is. That is what the SEO tools has detected.
-
So, what, is the SEO tool hallucinating that you have duplication? If it says there is duplicate pages then it should also be telling you what pages are the duplicates of each other. What you're doing is claiming that the canonical URL for a page is like /about.php. As far as I can see, URLs like that do not work. So this is going to create problems.
-
Read up on what Composer is and does. You don't need shell access on your host to make use of it.
-
Answers to my questions would be nice too. "ftpd" is very likely going to be an FTP server. If you need it then you should look into what's wrong, if you don't then you can shut it down. It kinda sounds like the http and https sides are running with different user credentials. Except that's weird.
-
If you haven't already, reach out to the hosting company: clearly something changed while the account was offline and it hasn't been undone. What's the hosting setup? Are there other users on that system, which you could tell by looking in /home for other usernames? Because it seems like there are, yet the save path is /tmp which would be shared with everyone and that's not good. The error names a particular file - does it happen to exist? What are the exact permissions and ownership on /tmp? It should probably be rwxrwxrwt, with that last letter "t" meaning sticky permissions and not "x" like normal, and probably be owned by root:root (and not, say, your own account). When your retry logging in and it works, look at your cookies for the PHP session id, then track it to the file in /tmp. What are its permissions and ownership?
-
Sure, but that won't stop anything - they'll just find a way around it, or do something else. The only solution to spam that actually has any effect is adding a captcha to the form. That's for bots, of course. For human beings, you'll just have to block them.
-
Describe (or draw) what you mean by "a vertically aligned line on either side of the text".
-
Modal will not open. Throwing Uncaught error...
requinix replied to Moorcam's topic in Javascript Help
Then, as before, there's something wrong with this particular modal or its setup. -
Modal will not open. Throwing Uncaught error...
requinix replied to Moorcam's topic in Javascript Help
https://www.google.com/search?q=bootstrap+modal+undefined+backdrop Looks relevant. -
It doesn't fit because it doesn't fit. Because there is too much text to fit in the space available. You could give the element more space, or shrink the font size, or reword it to be shorter, or you could just not worry about it fitting on one line.
-
The part where mac_gyver said that your preg_split()s could be simply explode()s is still true.
-
PHP Template Class Rendering with Arrays/Loops/PregMatch/PregReplace
requinix replied to Solar's topic in PHP Coding Help
This "2D" array is actually just a regular array like everything else, except that the keys are named like "0" and "1" instead of "logos". If I understand the way this works correctly, you should be able to write something like (0)(/name)(/0) to get Steven. If you don't want to write (0) or (1) then you'll have to figure out some new syntax... -
If you can create CSS rules that target mobile devices then you can create CSS rules that target desktops...
-
Opening one Bootstrap Modal from another Not Working
requinix replied to Moorcam's topic in PHP Coding Help
Shot in the dark, but you don't happen to be reusing that second modal's ID for anything else on the page, are you? Can you take the same (partial) markup, stick it into something like JSFiddle, and get it to work? -
Opening one Bootstrap Modal from another Not Working
requinix replied to Moorcam's topic in PHP Coding Help
Does their example work for you? Because if their example works then there's something different... -
Opening one Bootstrap Modal from another Not Working
requinix replied to Moorcam's topic in PHP Coding Help
Have you already compared what you have with their example of how to do two modals? Which worked for me... -
Opening one Bootstrap Modal from another Not Working
requinix replied to Moorcam's topic in PHP Coding Help
Been a while since I've done Bootstrap... Have you tried configuring it to open the other modal without closing the current one?