Need help with string.match()

Hello,Developers

Yesterday I started making something cool (seems cool for me at least) whenever you hover your mouse on a player’s character GUI pops up saying click to view this player profile but before I do that I need to have players profile description

Friends,Followers,Following
image
Place Visits and Join Date


i already made code that gets source of the website thanks to @IdiomicLanguage

But now I am struggling with string.match() because to get the numbers that I want require me to use string.match() which I don’t know exactly how to use it and nothing helped me at all when I searched it.

https://pastebin.com/Z4i71Tpn here is roblox profile html code

how can i get Followers,Friends,Following,Description,Join Date and Place Visits

2 Likes

It’s very difficult to use string.match to find html elements since it’s very conformative. I’d recommend finding the API endpoints for getting blurbs, bios and other profile details.

1 Like

The problem is I can not find any API endpoints that give me players description.

I’m assuming it’s somewhere in the JavaScript, because I believe roblox uses Angular and I’m pretty sure you need endpoints to use Angular. Maybe try checking chrome sources or network?

1 Like

I’m not sure of how to exactly use it. The proxy I use is rprxy.xyz. But this might give you a hint.

PlaceVisits is the textbox.

PlaceVisits.Text = "Place Visits: "…(string.match(extradata, "Place Visits<p class=text%-lead>(.-)<"))

1 Like

I somehow got Players join date like this

	local text = "Join Date<p class=text-lead>2/27/2006<li"
	
	print(string.match(text,"%d+/%d+/%d%d%d%d"))

Perhaps, something like this.

joindate = string.match(extradata, "Join Date<p class=text%-lead>(.-)<")

1 Like

That also works. It is better then the one I am using so I would use yours.

Place Visits

print(string.match(Respond.Body,"Place Visits<p class=text%-lead>(.-)<"))

So this means I can use this method (. -) to get users Followers, Friends, Following count.

Now only thing left is user description.

1 Like