Jump to content
View in the app

A better way to browse. Learn more.

Portal do Host

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Cep Automatico Atualizado! Melhorias

Featured Replies

Olá pessoal, procurei pelo CEP no WHMCS e encontrei uma versão que só funcionava com meu CEP antigo.

No github achei um script novo e adaptei com o antigo disponível no fórum.

Segue minha colaboração com o bando de dados diretamente do correio. É praticamente um webservice próprio =P

Ouvi falar que a biblioteca carregada é muito grande e não necessária. Não tenho conhecimento para analisar.

Existem algumas melhorias para fazer, quem quiser contribuir com melhorias, por favor fique a vontade!

Procure todos os $clientsdetails.postcode em seu template e adicione onblur + link do js:



{if $loggedin}{$clientsdetails.postcode}{else}<input type="text" name="postcode" id="cep" size="15" value="{$clientsdetails.postcode}" onblur="getEndereco()" />{/if}



<script type="text/javascript" src="js/jquery.js"></script>

<script type="text/javascript" src="js/cep.js"></script>


Se você já utilizava a versão antiga somente baixe e envie a pasta /js para a raiz do whmcs.

Em breve estarei postando um script para newsletter de aniversário do cliente.

Abraços


  • Author

Melhorias:

Remover Numeração do logradouro ou

Colocar ela no Endereço2 ou em um custom field Nº/Complemento

Segurança para bloquear acesso externo

Trocar o estado que está em select em certos templates.


Então tentei fazer o evento onblur no postcode não deu, notei que onblur não aparecia e nem carregava os arquivos js


Guest
This topic is now closed to further replies.

Recently Browsing 0

  • No registered users viewing this page.

Important Information

Do you agree with our terms?

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.