34 Replies
the goal is too change the href to 1 of the const codes when the code is correct
if(inputValue in codes)
is not a valid statement to check if an object key excists.
try
tried this now but only 1313 works and not 2005 @MarkBoots
hard to tell with the screenshots. in the first one you share getElementByClassName (which returns a list) not a single value, and now you do a queryselector that should be correct.
what is the error you get in the console?
even better, make a codepen so we can check it out ourself.
codepen?
#how-to-ask-good-questions
https://codepen.io/blopblip/pen/YzgxBBj
is this fine?
ah okay, you have to be more specific with selecting the correct <a> element to change the url. give each a unique id and select that in the if-statements
why not with query?
and how would i implement them cuz im kinda braindead at 1 30 at night rn :/
then you have to come back tomorrow. you decide to post a question in the middle of the night
for me it is night too, im going to bed.
i did 3 hours ago gonna finish it now
bro pls help cmon
Please be respectful for others time. People are helping on their own freetime here.
im stuck for 3/4 hours at 2 midnight
No one forced you to start your homework the night before it was due
it is not about me but don t wanna fail cuz of shitt team an
can pay ig
Bruh lol just take the L on this and start your assignments earlier next time
bro i failed alr cuz of my shitteam
or do what devs do and research and find a solution on your own 🤷♂️ its out there or rethink your approach to find a solution. Lets not continue this path though, just remember to be patient when asking for help here. Everyone that helps is a volunteer that likes to help out of good will and nerd snipping.
Vince I appreciate your candor but I had already said something lets not stir fires please.
What do you need help with anyway? Can you explain it in plain english and I can help maybe
to change the link to the correct path when the code is correct
so like 1313 works
but need this one to work filepath is 100% right
Why is it in an interval?
interval?
dunno someone else wrote that
but do you know how to fix the 2005 in it then it is done
so any idea how to fix it?
thx for ghosting f you all 😉
I was putting it in codepen
I just spent 20 min even after you were super entitled, and I could be super petty and not give it to you but here https://codepen.io/vince1444/pen/PoLKLZr
You will no longer be getting help from me
I'd grab that link fast before I ban you
Cause we don't need this kinda attitude around here, no ty.
Lol did you ban them
ya ofc
sorry if your effort is wasted, I really appreciate you helping even after they were they way they were.
No worries, it wasn't. Whenever I talk 💩 I feel like I need to at least be some help. Plus it was a learning experience for me as I've never really done something like that before
I gave them the time they expected from us to get the solution