Saturday, May 19, 2018

Link to a specific part of a page - development

Link to a specific part of a page

I have a div that has lots of posts which is created dynamically from the database. The div has input for comment facility as well. I have no problems in posting the comments and I do it using a POST method. Then I redirect to the page using return redirect('/'); method. But it links to the beginning to the page which doesn’t create a good impression on the user. The user might be in the middle of the page and when he/she comments he will go to the beginning of the page and will have to scroll down again. Luckily, I have the divs with class equal to the post_id. So, isn’t there any method to go to the post in which the user posted using that class?



from Laravel Questions and Answers https://laravelquestions.com/php/link-to-a-specific-part-of-a-page/
via Lzo Media

No comments:

Post a Comment