Jump to content

ginerjm

Members
  • Posts

    6,906
  • Joined

  • Last visited

  • Days Won

    99

Everything posted by ginerjm

  1. No it doesn't. Does the API that you call (1) actually generate this display, or do you (2)do the displaying. If 1 - the api has to be aware of your "new" query item in order to affect the behavior. If 2 - Of course you can!
  2. You have some extra hidden chars at the end of this line right before $ratio_orig is ref'ed list($width_orig, $height_orig) = getimagesize($imgSrc);
  3. Would have been nice if you pointed out where line 23 was.
  4. Does the php script get executed BEFORE the video is shown? If so then the update has to occur. I don't buy the idea that joomla caching your html output will interfere with your php script that builds it. Your click triggers a php script, correct? If so then that php script HAS to run and if your logic is correctly placed it has to run and your count has to be incremented. That has to happen!
  5. So - you do have a php script. And you know which video is to be shown. So the first thing that script should do is to update your counter table. How does a joomla cache interfere with that?
  6. Sorry. Dont' know what this last set of code has to do with "1 to 4". Have you tried to show the id values you get in your first query before you continue on with all the rest of the code? What do you see when you do that? BTW - you should prepare the query ONCE - outside the loop - and then just bind the values inside the loop. That's the whole point to having a prepared query.
  7. What handles that click action? You say that a "php script runs". So? Why doesn't that script update the count?
  8. What the heck is this line: $rows = $xpath->query("//span[@class='price']"); That line has to give you some kind of error. What are you trying to do there?
  9. Some of us don't just click on links provided in posts. Some of us want specific answers to question or specific code that has a problem. Maybe you could answer my last question instead of posting whatever you just posted.
  10. Urgent? Really. You need something "urgent"?. Better get writing then.
  11. Are you sure this is PHP you are discussing? I may be new and these may be old, but my search of the manual did not turn up any use of "see" (or @see) nor FQSEN.
  12. We need to do some definitions clearing up here. Your article talks about "article" hits. Can you define for me what pages you are attempting to count? If you are displaying a requested document (not a script) and want to have it counted every time it is requested, that is definitely not what we(?) have been giving you. Of course I can see why joomla as well as a browser would give you the cached copy instead of a new one. So - when the user clicks on whatever you have on your webpage in order to see a new document, what actually happens? Is there a form submit to a php script? Or at least an anchor href pointing to a php script?
  13. Why don't you pick ONE problem and show us that code? Perhaps if we solve that one, the others will fall into place for you. Key thing is to Show the Code.
  14. So then perhaps you should direct this topic to a CMS forum, or even a Joomla one.
  15. That code is pretty weak looking. You test two things to see if they failed, but when they do you don't output anything to tell you they failed. Echo-ing out an empty string as you do is not very helpful when something didn't work. And if it didn't work you continue on with the rest of the script anyway. Why? To top it all off - you then do your update query and once again you test for failure but don't put out a message whether it actually updated or not. As for caching - how does a php script get cached on the browser since it only exists on the server?
  16. To be accurate - you haven't posted YOUR code. Humor us and show us what you have typed up so that we can be sure that we are looking at your running code.
  17. I don't know how you are doing this that makes the cache affect you. I do this all the time. Every time my script executes it checks if it has already been run and is processing a response, or if it is the "first" time it has been called. If it is the "first" then I increment my counter. Obviously this won't tally up refreshes, but why would you want to do that? It doesn't tell you anything about usage. So - show us your code for keeping your hit counts so we can see why the cache is affecting you.
  18. It's simply a matter of uploading a file - video or not. Plus - you really shouldn't be saving video files (or image files) in a table. There is no reason to do that. The file can be pointed to (by name) from a db table that may contain information about it, but you don't need to save the file also in that table. Create a default folder for your video/image files and link to them from the table. Also - do some googling (or read the manual) for how to upload files with php.
  19. Read the manual to see how you should be writing the mail() call. You're missing something.
  20. My phpinfo does not show an element called HTTP_CACHE_CONTROL - does yours? I realize that you are trying to avoid repeated F5 hits here but is it really necessary. Why not just trigger "new" hits on a page with a snippet of code and a function that logs the data? I woule just check if there existed a submit value that comes from the current page; if it doesn't then it is a new visit to the page and I would log it. If not, I wouldn't.
  21. When you finally do write some code and have a problem with it, post it here with your question and any pertinent error messages.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.