Home › Forums › Front-end Issues › Accept only unique values › Reply To: Accept only unique values
Sorry, I’m trying to have a unique value for the sub-field in one post. I am creating a gallery page. Each page has several groups of images (gallery groups). I would like to have a unique ID (<div id=”home-entertainment”>) that I can use as an anchor to link to.
For example:
<div class="gallery-group" id="home-entertainment">
<h2>Home Entertainment</h2>
<img src="image1.jpg" />
<img src="image2.jpg" />
</div>
<div class="gallery-group" id="home-security">
<h2>Home Security</h2>
<img src="image3.jpg" />
<img src="image4.jpg" />
</div>
<div class="gallery-group" id="home-automation">
<h2>Home Automation</h2>
<img src="image5.jpg" />
<img src="image6.jpg" />
</div>
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.