I would like to make a snippet that uses the select text twice instead of once.
For example, an option tag:
<option value="optionText"> optionText </option>
There are actually a number of situations involving js/php that I want this to work for, also.
Is there a way to do this? Right now I can only put in once instance and always have to type or paste the other.
Not sure exactly what you are saying..you do know that you can make a snippet that 'wraps' (puts in a bit before your selection and a bit after your selection)?
But it sounds as if you want to be able to type in "optionText" once and have it appear in two places, which is trickier.
Here's a thought: make a snippet that looks like this:
and wraps, to put at the end:
type in your optionText, select it and copy it. Then while it is selected, insert the snippet, wrapping the optionText.
Then paste the optionText from the clipboard, type </ and the rest of option> should fill itself in. Do Edit > Preferences > Code Hints > Close tags after typing </ to set it up.
I have a suspicion that you may be able to get fancier than this with snippets, but I haven't done so...