Not sure I see how having my server call the page and the client call the server saves time. That's two calls the client has to wait to complete, not just one.
Your server should call and process the info more efficiently than a browser The feed that the user eventually gets will be smaller - important if they're on mobile or even wifi - they're downloading a small json feed, not an entire webpage The processing is reliable because you have control over your server and all browsers can manage a json feed. You don't have to worry about cors issues. Here's an challenge, I haven't done one of these in a while. Scrape https://forums.digitalpoint.com/find-new/posts and show each link on a page Then take this feed https://www.itamer.com/muck/dpnewthreads.php and display each link on a page which is quicker? bearing in mind that itamer.com is on very average shared hosting and may be slower than your hosting. Here's a codepen - which will also be slower than in live but it gives you some code to get started https://codepen.io/itamer/pen/ZEaJqzr
OK, sounds like the idea is worth testing. But whatever way I do it, I still need to know: is the method I used above capable of returning the html code, or do I need to do something different?
It's capable, and I've shown it working (slowly). Your stumbling block is CORS. If the site isn't letting you scrape then you can't use javascript.
OK, so I am going to try out your processing it on the server and outputting the data as json idea, but I must again reiterate my limited knowledge of these programming languages. In the foreach code in the example you gave, say I wanted each div name put in the form of a string like so: "name1/name2/name3," how would I do that? The string would be stored in $output"
foreach ($divs as $div) { ... whatever you need to do... save result in $output } PHP: concatenating/adding strings together is the easy part. $output = "$name1/$name2/$name3," PHP: I'm just not sure where you're getting the $name1 etc from. you may need to build in more loops etc.
The names are from the div tags. The thing I'm looking for. It's not string concatenation I was asking about, but where the data I'm looking for can be found. I am unfamiliar with the foreach command. Or json. Foreach? $divs as $div? Greek to me. I'm gathering your code takes the html data and organizes it in some way, but beyond that, I've no idea what you're on about here.
Then you have to do some experimentation & learn. or share the page you're scraping along with your desired outcome. Your name1, name2 wasn't clear either since I have no idea what the structure of your source data is.
I work full time and have much else on my plate besides. I have no time to go experimenting and learning theory. I just need a simple question answered: using this technique, what code will allow me to take the names of divs and put them in a variable?
Google is your friend The PHP example is in post #26 Javascript is just let myVar = var1 + "/" + var2; Code (JavaScript): We all have work to do, and commitments. We try to help but you have to do some of it yourself. You need to make the time for experimenting and learning or else you're going to be stuck when the source page changes something and breaks your code. How are you going to create your app if you have no time for learning? Even with tools like bubble and jasonelle you have things you have to learn.
Don't presume to tell me what I am or am not capable of doing, or of what I need down the line. I'm a high functioning autistic savant. I'm quite capable of doing rather a lot with just an example or two, and I learn much more quickly that way than I do studying in the way that works for neurotypicals. If you don't want to answer my question, fine. Nobody's forcing you to. But just say you don't want to take the time. Or just don't respond. Don't talk down to me. I'm not your student. I'm not your child.
@sarahk has gone out of her way to help you on this thread and this is how you respond? If you don't wish to be treated like a child, then don't behave like one.
Help me? By never answering direct questions? By dragging out what should have just been my quickly checking on a couple of facts? By arrogantly telling me what I need to do instead of respecting my ability to know what I need myself? I don't know how they do things where you come from "Spoiltdiva," but where I come from, refusing to answer a direct question is considered rude, and making decisions for other people is considered even ruder. OK, I see I need to find a place with adults. See ya. So to speak.
You were in the discussion section of the forum - this is where we discuss stuff. If you wanted to hire someone to do it we have a whole section for that! Then you should find all of this easy and not be stuck concatenating strings FFS. One thing to bear in mind is that programmers are, mostly, neurodivergent and your autism is considered "normal" here.
If you have no time to work at this, HIRE someone to do it for you. If you cannot afford the money or the time, then table the project until you can afford it. Further, we are here to point you in the right direction, NOT to hold your hand and do your job. If you have no time for this, there is no reason for you to expect help from us nor from anyone else.
At least we had the courtesy to respond to his posts... https://www.constant-content.com/fo...&t=77057&sid=dacac6c2e8e9001aebc0e3c3d39d8e2b https://forums.javascriptpros.com/threads/can-javascript-do-this.16/ Whoever runs javascriptpros got bored quickly - thread #16 and the owner couldn't be bothered!