hangi dosyada çalışmasını istiyorsan,
{if $smarty.server.SCRIPT_NAME == '/cloud.php'}
....
{/if}
noktaların olduğu yere yani if içine al js leri head kısmında.
sadece cloud.php deyken head de çalışır.
yani,
<html>
<head>
{if $smarty.server.SCRIPT_NAME == '/cloud.php'}
<script src="//code.jquery.com/jquery-1.11.3.min.js"></script>
{/if}
</head>
<body>.....
yazdık mesela,
jquery sadece cloud.php de çağırılır.
Hocam ekledim ancak kaynakta görünmüyor halen çalışmadı acaba ben mi yanlış yapıyorum?
Edit.
Tamamdır dizini yanlış yazmışım. Allah razı olsun vallahi siz bu işin üstadısınız.
--R10.NET; Flood Engellendi -->-> Yeni yazılan mesaj 02:03:45 -->-> Daha önceki mesaj 01:56:09 --
hangi dosyada çalışmasını istiyorsan,
{if $smarty.server.SCRIPT_NAME == '/cloud.php'}
....
{/if}
noktaların olduğu yere yani if içine al js leri head kısmında.
sadece cloud.php deyken head de çalışır.
yani,
<html>
<head>
{if $smarty.server.SCRIPT_NAME == '/cloud.php'}
<script src="//code.jquery.com/jquery-1.11.3.min.js"></script>
{/if}
</head>
<body>.....
yazdık mesela,
jquery sadece cloud.php de çağırılır.
Hocam çok teşekkür ediyorum bu bilgi için. Birde ekstra sorum olacaktı;
header.tpl 'de şunları çekmişim tüm sayfalarda çalışsın diye:
<link href="templates/{$template}/css/style.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="templates/{$template}/css/simpleslider.css" />
<link rel="stylesheet" href="templates/{$template}/css/musteripaneli.css" />
<script src="templates/{$template}/js/jquery-1.6.4.min.js"></script>
<script src="templates/{$template}/js/jquery.easing.min.js"></script>
<script src="templates/{$template}/js/jquery.simpleslider.min.js"></script>
<script src="templates/{$template}/js/jquery.touchwipe.min.js"></script>Şimdi dedicated.php için şunları ekledim:
{if $smarty.server.SCRIPT_NAME == '/whmcs/dedicated.php'}
<script type="text/javascript" src="templates/{$template}/js/jquery.pTab.min.js"></script>
<script src="https://code.jquery.com/jquery-1.10.2.js"></script>
<script type="text/javascript" src="templates/{$template}/js/jquery.custom.js"></script>
<script type="text/javascript" src="templates/{$template}/js/maxr.js"></script>
{/if}Ancak o header.tpl de bulunan bazı js ler ile bunlar çakışıyor dedicated.php deliriyor.
O header.tpl de ki ilk js lerin dedicated.php de
çalışmamasını isteyemez miyiz?