Short Url Domain

operbot844

New Member
Wurlie User
Jun 14, 2010
8
0
1
Hi

Can i remove the Short Url Domain box on the frontpage so it is not visable or something like that ?
 

ysmods

New Member
Jan 29, 2013
860
1
0
UK
www.ysmods.com
Open index.php

Find:
Code:
<div>
                            <label for="shortUrlDomain"><?php echo t("short_url_domain", "Short Url Domain"); ?>:</label>
                            <select id="shortUrlDomain" name="shortUrlDomain" style="width: 100%;">
                                <?php
                                foreach ($shortUrlDomains AS $k => $shortUrlDomain)
                                {
                                    // active domains only
                                    if($shortUrlDomain['status'] != 'enabled')
                                    {
                                        continue;
                                    }
                                    
                                    // disabled item
                                    $disabled = false;
                                    if(($shortUrlDomain['premium_only'] == 1) && ($Auth->level == 'guest'))
                                    {
                                        $disabled = true;
                                    }
                                    elseif(($shortUrlDomain['premium_only'] == 2) && (in_array($Auth->level, array('guest', 'free user', 'user'))))
                                    {
                                        $disabled = true;
                                    }
                                    
                                    // check for account only
                                    if(($shortUrlDomain['premium_only'] == 1) && ($lastPremiumOnly != $shortUrlDomain['premium_only']))
                                    {
                                        echo '<optgroup label="'.safeOutputToScreen(t("registered_users_only", "Registered Users Only")).'">';
                                    }
                                    
                                    if(($shortUrlDomain['premium_only'] == 2) && ($lastPremiumOnly != $shortUrlDomain['premium_only']))
                                    {
                                        echo '</optgroup>';
                                        echo '<optgroup label="'.safeOutputToScreen(t("paid_users_only", "Paid Users Only")).'">';
                                    }
                                    
                                    $lastPremiumOnly = $shortUrlDomain['premium_only'];

                                    echo '<option value="' . (int) $k . '"';
                                    
                                    // selected option
                                    if ($k == (int) $_REQUEST['shortUrlDomain'])
                                    {
                                        echo ' SELECTED';
                                    }
                                    
                                    // disabled option
                                    if($disabled == true)
                                    {
                                        echo ' disabled="disabled"';
                                    }

                                    echo '>';

                                    echo $shortUrlDomain['domain'];
                                    if($disabled == true)
                                    {
                                        echo ' ('.safeOutputToScreen(t('unavailable', 'unavailable')).')';
                                    }
                                    
                                    '</option>';
                                }
                                echo '</optgroup>';
                                ?>
                            </select>
                        </div>
Replace with:
Code:
<!-- <div>
                            <label for="shortUrlDomain"><?php echo t("short_url_domain", "Short Url Domain"); ?>:</label>
                            <select id="shortUrlDomain" name="shortUrlDomain" style="width: 100%;">
                                <?php
                                foreach ($shortUrlDomains AS $k => $shortUrlDomain)
                                {
                                    // active domains only
                                    if($shortUrlDomain['status'] != 'enabled')
                                    {
                                        continue;
                                    }
                                    
                                    // disabled item
                                    $disabled = false;
                                    if(($shortUrlDomain['premium_only'] == 1) && ($Auth->level == 'guest'))
                                    {
                                        $disabled = true;
                                    }
                                    elseif(($shortUrlDomain['premium_only'] == 2) && (in_array($Auth->level, array('guest', 'free user', 'user'))))
                                    {
                                        $disabled = true;
                                    }
                                    
                                    // check for account only
                                    if(($shortUrlDomain['premium_only'] == 1) && ($lastPremiumOnly != $shortUrlDomain['premium_only']))
                                    {
                                        echo '<optgroup label="'.safeOutputToScreen(t("registered_users_only", "Registered Users Only")).'">';
                                    }
                                    
                                    if(($shortUrlDomain['premium_only'] == 2) && ($lastPremiumOnly != $shortUrlDomain['premium_only']))
                                    {
                                        echo '</optgroup>';
                                        echo '<optgroup label="'.safeOutputToScreen(t("paid_users_only", "Paid Users Only")).'">';
                                    }
                                    
                                    $lastPremiumOnly = $shortUrlDomain['premium_only'];

                                    echo '<option value="' . (int) $k . '"';
                                    
                                    // selected option
                                    if ($k == (int) $_REQUEST['shortUrlDomain'])
                                    {
                                        echo ' SELECTED';
                                    }
                                    
                                    // disabled option
                                    if($disabled == true)
                                    {
                                        echo ' disabled="disabled"';
                                    }

                                    echo '>';

                                    echo $shortUrlDomain['domain'];
                                    if($disabled == true)
                                    {
                                        echo ' ('.safeOutputToScreen(t('unavailable', 'unavailable')).')';
                                    }
                                    
                                    '</option>';
                                }
                                echo '</optgroup>';
                                ?>
                            </select>
                        </div>-->
						<input type="hidden" name="shortUrlDomain" value="1" />
 

pascal4039

New Member
Wurlie User
Reservo User
Jun 18, 2014
10
0
1
Hey,

thanks.

But if i try to create a link on another website via Bookmark, the error message comes again:
 

Attachments

pascal4039

New Member
Wurlie User
Reservo User
Jun 18, 2014
10
0
1
I think so.
When I'm on the startpage there's at the bottom a link "Add Bookmark".
I dragged that into my bookmark in my chrome.

If i use this on any page, the system asks for the domain which should used.
 

pascal4039

New Member
Wurlie User
Reservo User
Jun 18, 2014
10
0
1
Thanks, this works great =)
Nowi hope i translated nearly the whole system into german.

I like it =)