Jump to content

Intodns?


ljesh

Recommended Posts

It seems clientshosting.php (I guess in this file this needs to be added) is encoded, and this is impossible to be performed :(

 

You may close/delete this thread, I hope WHMCS does this for us. It will be an extra tool to ease our work sometimes.

Link to comment
Share on other sites

It seems clientshosting.php (I guess in this file this needs to be added) is encoded, and this is impossible to be performed :(

 

You may close/delete this thread, I hope WHMCS does this for us. It will be an extra tool to ease our work sometimes.

 

NEVER SAY IMPOSSIBLE! Cause possible is my middle name - Well I not really... but I like to do the impossible.

 

Insert this into your admin template footer.tpl file:

 

{literal}
<script type="text/javascript">
var domainVal = $('input[name=domain]').val();
if (domainVal != (""|null|undefined)) {
$('input[name=domain]').parent().append(' <a href="http://intodns.com/'+domainVal+'" target="_blank">intodns</a>');
}
</script>
{/literal}

 

- Enjoy!

From your friendly neighbour hood developer!

Link to comment
Share on other sites

  • 1 month later...
  • 8 months later...
  • 1 year later...
  • 6 years later...
2 minutes ago, baymax said:

So... how does one go about adding a new link to the current version of WHMCS?  For both products/services & domains, I can't find it anywhere!

Same old way, jQuery.

<?php

add_hook('AdminAreaHeaderOutput', 1, function($vars)
{
    $output .= <<<HTML
    <script type="text/javascript">
    $(document).ready(function(){
        $("#intellisearchval").closest('div').append('<img src="https://katamaze.com/templates/kata/img/stuff/nyan-cat.png" style="height: 27px;width: 180px;">');
    });
    </script>
HTML;

    return $output;
});

Here's the output:

nyan-cat-whmcs.png.4a11685873e71fec6ac363be42df0338.png

AdminAreaHeaderOutput provides variables you need to inject your code in specific pages. As for jQuery, just play with selectors.

Link to comment
Share on other sites

<?php

add_hook('AdminAreaHeaderOutput', 1, function($vars)
{
    if ($vars['filename'] == 'clientsservices')
    {
        $output .= <<<HTML
        <script type="text/javascript">
        $(document).ready(function(){
            $('input[name="domain"] + div').children('ul').eq(0).append('<li><a href="https://www.youtube.com/watch?v=QH2-TGUlwu4" target="_blank"><img src="https://katamaze.com/templates/kata/img/stuff/nyan-cat.png" style="height: 27px;width: 180px;"></a></li>');
        });
        </script>
HTML;

        return $output;
    }
});

Here is the output.

nyan-cat-2.png.d9a0f83ee66a84889d966b81ddad281b.png

 

Link to comment
Share on other sites

3 hours ago, Kian said:

<?php

add_hook('AdminAreaHeaderOutput', 1, function($vars)
{
    if ($vars['filename'] == 'clientsservices')
    {
        $output .= <<<HTML
        <script type="text/javascript">
        $(document).ready(function(){
            $('input[name="domain"] + div').children('ul').eq(0).append('<li><a href="https://www.youtube.com/watch?v=QH2-TGUlwu4" target="_blank"><img src="https://katamaze.com/templates/kata/img/stuff/nyan-cat.png" style="height: 27px;width: 180px;"></a></li>');
        });
        </script>
HTML;

        return $output;
    }
});

Here is the output.

nyan-cat-2.png.d9a0f83ee66a84889d966b81ddad281b.png

 

hey Kian, thanks so much. What if I want it to auto append a URL/domain/hostname after the URL?

Link to comment
Share on other sites

If I understoon you correctly...

<?php

add_hook('AdminAreaHeaderOutput', 1, function($vars)
{
    if ($vars['filename'] == 'clientsservices')
    {
        $output .= <<<HTML
        <script type="text/javascript">
        $(document).ready(function(){
            var url = $('input[name="domain"]').val();
            $('input[name="domain"] + div').children('ul').eq(0).append('<li><a href="https://example.com/hello.php?domain='+ url +'" target="_blank"><img src="https://katamaze.com/templates/kata/img/stuff/nyan-cat.png" style="height: 27px;width: 180px;"></a></li>');
        });
        </script>
HTML;

        return $output;
    }
});

The rainbow cat will open example.com/hello.php?domain={THE_DOMAIN_WRITTEN_IN_THE_INPUT}.

p.s. If you are a real man, leave the rainbow cat in production! 😎

Edited by Kian
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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • 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