Jump to content

Merge domain TLD Dropdown into one input field


USA_Webmaster

Recommended Posts

May you please help point me in the right direction? I'm using "Modern" Cart plus Six theme design.

 

• How do I combine input value="{$sld}" and input value="{$tld|substr:1}" into one field?

 

The two php snippets I'm looking at in configureproductdomain.tpl file are:

 

input type="text" id="owndomainsld" value="{$sld}" .....

 

AND

 

<input type="text" id="owndomaintld" value="{$tld|substr:1}" .....

 

I'm browsing over the Registrar Module Dev Docs but don't understand everything...I wish to combine "I will use my existing domain and update my nameservers" input fields into one. Customer may type "domain" and the "TLD" all at once without tabbing.

 

fqZF35l.png

 

Thanks for taking a look at the thread.

 

---

 

similar feature request --> https://requests.whmcs.com/topic/merge-current-domain-checker

similar idea --> http://forum.whmcs.com/showthread.php?109551-Cart-combine-domain-register-and-transfer-into-one-field&highlight=combine+domain+checker

 

p.s. - if anyone wants the code i'm using right now just let me know

Edited by USA_Webmaster
formatting + updated with picture
Link to comment
Share on other sites

• How do I combine input value="{$sld}" and input value="{$tld|substr:1}" into one field?

I don't think you do want to combine them into one field - the cart will be expecting $sld and $tld to be passed separately and will likely not function if it doesn't get them...

 

the only two options I can see would be to either have one field and then split the entered values into $sld and $tld - perhaps in jquery or a hook... or bypass the $sld/$tld validation, enabling you to pass $sld (domain.com) and then split it into $sld and $tld at the next stage (domainoptions.tpl).

 

i'm struggling to recall a thread of something attempting this before, but I can't recall anyone trying. :?:

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated