-
Posts
14,780 -
Joined
-
Last visited
-
Days Won
43
Everything posted by .josh
-
are you asking where to add id=xx to the url link inside that pagination script? // while there are rows to be fetched... while ($list = mysql_fetch_assoc($result)) { // echo data echo $list['id'] . " : " . $list['name'] . "<br />"; } // end while Is where you would be listing your data. From your link in your post, your data is links. You need to add id=xx to those links but you also need to add the currentpage=xx to those links to preserve the current page you are on. xx would be $currentpage (like in the part of your script that checks whether to make the page number a link or not because you are on that page, you would use that same var).
-
[SOLVED] Finding a piece of a string from X character to X character
.josh replied to Gleasonator's topic in PHP Coding Help
substr -
Captain, where is my logic failing me? Sessions
.josh replied to Beauford's topic in PHP Coding Help
it would be easier to do it through a database. You would have a column for "last active" and just select lastactive where lastactive is less than 10m or whatever. -
assuming you know how to connect and query etc.. use SUM select sum(column) as blah from table
-
I will agree that in many cases it's overkill and not necessary but that's not the same as saying it's bad, as those articles were asserting.
-
perhaps eval is what you are looking for?
-
single quotes do not parse variables.
-
How might what look? An array? A loop? What have you tried? Have you looked at what the gd library has to offer?
-
Okay so I view source code and I don't see anything from that posted code being echoed, not even the stuff outside of your while loop, so...are you sure that that code snippet is uploaded or relevant to that page?
-
[SOLVED] prevent from REPETITIVE ENTRANCEs in DB
.josh replied to msafvati's topic in PHP Coding Help
google for any registration script tutorial and you will find method(s) for checking if there is duplicate data in your db. -
Would help if you explained what "It's not working" means.
-
without actually testing anything, my gut impulse is to say your floors are chopping off remainders that would otherwise have been translated into that extra minute.
-
You can take all those rand(x,y) numbers and stick it into an array (a multi-dim array would probably be better) and then loop through the array.
-
when you get around to reading up on cron jobs, you will find that it's basically telling the server to run your script every X time.
-
What's a patatic?
-
cron job
-
...and from "AJAX and the road to bad websites": Again, all those arguments against AJAX are beefs with design flaws. The author of that article even admits it at the end of his article: That pretty much sums up my previous post.
-
From "Why Ajax Sucks" This can easily be solved by creating a unique id based on what is being "tweaked" on the page. For instance, if I am customizing a computer at some online store, there are several options for several components. Ram options, HD options, monitor options, processor options, etc... Each component can be represented by a value and those values can be stored in a specific position in a string. I (as the store) can then take that string and parse it and rebuild exactly what was selected. My point is, I do not think it's a failure on AJAX's part that people cannot send a link of what exactly they are looking at, to other people. I think it's a failure on the programmer's/designer's part to implement a system of data persistence. This is bullshit. AJAX is a javascript method. It is nothing special or different or separate from something. It is javascript. If someone cannot use ajax, it is because they either don't have a browser that handles javascript (virtually non-existent) or else they have javascript disabled. And again, even the author admits that the real problem is laziness on the designer's part to accommodate those situations. This argument is so weaksauce I don't even want to acknowledge it. The BACK button continues to work exactly as it was made to work: it takes you back to the previously clicked url link. If you are having issues of going "back" to a previous decision/path/etc... within a specific page, then yet again, that's a design flaw of that page. Once again I call bullshit. Printing difficulties are a result of a failure on the designer's part, not on AJAX. A good design will involve being able to navigate to a printable version of a page in the first place. "Should only the visible part be printed or all of it? (paraphrased)" That is irrelevant to AJAX. Printing should be done in a WYSIWYG manner. If a page uses ajax to dynamically show/hide data, and you have something hidden then it should not print that hidden part. If you get upset because it's hidden, then click the damn button that shows it. If you want to argue that there's a hundred buttons and you shouldn't have to click them all to get a printout, then take it up with the designer. He should have a "toggle all" button somewhere, or something. The point is, that's a user or else design problem. Yet another stupid argument, because this can be argued for anything beyond simple HTML, be it dhtml, javascript (even thought ajax IS javascript), php, asp, cgi, etc.. etc.. in short, anything that makes a webpage dynamic. And that's why it's a stupid argument. It's singling out ajax, when it's a "problem" for virtually everything. That statement just reeks of "I should be able to make webpages do whatever I want to without having to actually learn anything. Who do I talk to for that magic wand?" If we subscribed to that logic, we'd still be riding bikes instead of driving cars, because driving a car is harder and it's harder to make a car and fix a car and etc... Once again, that's a failure on the designer's part. lrn2SEO. Proof? I don't see any proof of that. Where's the proof? There is an obvious typo in that statement. Don't worry, I'll fix it: "If given the choice between regular and ajax versions, I prefer ajax-free designs...and since I prefer it, everybody else must prefer it as well." There you go Mr. Author, got that all fixed up for you. No worries. What the hell? This whole time he's been arguing that AJAX breaks the internet experience, is flawed in 10 million ways, and most of the time is not even correctly implemented. And yet he says it's okay to use it as proof of one's technical expertise? OH TEH IRONIES. Gee. I mean, I'm no expert, but doesn't that sound just like AJAX (or javascript in general)? Fail.
-
Expanding/rewording what Ken2k7 said, if you have a field in your db that signifies whether something is (supposed to be) checked or not, you can add a condition in your loop that displays your images/etc.. If you are wanting something to be dynamically (not) shown based on whether the user checks something right then and there, you're going to have to do some event handling with javascript. We could be a bit more specific if you were to be a bit more specific in what you're goal here is.
-
If I understand you correct, you're lookin' to just do some Basic Database Handling.
-
yeah...I bet they pretty much become masters of the universe for all portable devices.
-
Obviously. You gave him the warning. It's up to him whether to accept it or not. I'm not going to judge his situation. Warning him about it is enough IMO.
-
If you want someone to write code for you, post in the freelance section. We don't do that sort of thing over here. You might find what you're looking for by looking into captcha tutorials.