Update 48 (2011.11.20)

Post Reply
admin
Site Admin
Posts: 37197
Joined: Wed Sep 10, 2008 11:43 am

Update 48 (2011.11.20)

Post by admin »

[news_title]Counters and spiders, Models and more[/news_title]

Update 48

Rotation

Models

Model has been added in this update (Rotation - Models), basically it's quite the same as sponsors\categories, ie each thumb\gallery can have any amount of models linked to it. Also 2 templates were added to display list of models (model_list) and list of model's galleries (model_galleries). Also you have to add some rewrites to beautify
your links

Code: Select all

 

RewriteRule ^models/$ /scj/tube/?force_template=model_list [L]
RewriteRule ^models/(.*)/$ /scj/tube/?force_template=model_list&model_first_letter=$1 [L]
RewriteRule ^model/(.*)/(.*)/(.*)/$ /scj/tube/?model_slug=$1&force_template=model_galleries&order=$2&page=$3 [L]
RewriteRule ^model/(.*)/$ /scj/tube/?model_slug=$1&force_template=model_galleries [L]

add this to  .htaccess  or nginx\lighttd config
 

Default link to output models: http://domain.com/models/

How to output list of models in template (note, you can output list of models on any page, exactly as categories):

Code: Select all

 
<models num=1-3>
<li><a href="/model/<!--MODEL_SLUG-->/"><!--MODEL_SLUG--> (<!--TOTAL_ITEMS-->)</a></li>
</models>

outputs first 3 models (alphabetically by default)
 

Output models with names starting with some char

Code: Select all

 
<models order=alphabet num=1-3 first_letter=a>
<li><a href="/model/<!--MODEL_SLUG-->/"><!--MODEL_SLUG--> (<!--TOTAL_ITEMS-->)</a></li>
</models>

Outputs first 3 models with names starting with A
 


One more interesting option

Code: Select all

 

If you link like http://domain.com/models/a/

and template looks like

<models order=alphabet num=1-3 first_letter=GET_MODEL_FIRST_LETTER>
<li><a href="/model/<!--MODEL_SLUG-->/"><!--MODEL_SLUG--> (<!--TOTAL_ITEMS-->)</a></li>
</models>


script will output models starting with "а".

with link http://domain.com/models/b/ - starting with "B" and so on.
 
Additional parameters for models tag

Code: Select all

 

Output models with at least 10 galleries 

<models order=alphabet num=1-10 gallery_count_min=10>
      <li><a href="/model/<!--MODEL_SLUG-->/"><!--MODEL_NAME--> (<!--MODEL_TOTAL_GALLERIES-->)</a></li>
</models>


output sorted by average gallery CTR

<models order=model_ctr num=1-5>
      <li><a href="/model/<!--MODEL_SLUG-->/"><!--MODEL_NAME--> </a></li>
</models>

Sorted by gallery amount

<models order=count_galleries num=1-5>
   <li><a href="/model/<!--MODEL_SLUG-->/"><!--MODEL_NAME--> (<!--MODEL_TOTAL_GALLERIES-->)</a></li>
</models>


 

And, of course, there some new options in Import to handle models. New options: Models and "Parse description for model name", and new options in pattern: Models и Models (autocreate).

* If you choose models in pattern and models exist - script will link those models to imported gallery. If you import for example http://gallery|desc|model1,model2|http://thumb), and model1 exists, but model2 - doesnt, script will link to model1 only.
* If you select "model (autocreate)" script will also create model2 and link to both models
* Pattern is more important then "Models" option.
* With "Parse description for model name" script tries to find names of existing models in description.

Groups (Categories) Tree

You can have a category tree or folder format , whatever you call it. Let's say we have 2 group of upper level: cars and monitors. Inside cars group: audi, bmw, honda, toyota. Inside monitors: benq, acer, samsung.

Surfer navigates to group "cars" and we want to output only subcategories of this group:

<category order=alphabet num=1-5 subcategories_only=true>


INCLUDE_FILE

If you have to include some file in your templates easiest way to do it

<!--INCLUDE_FILE_/home/user/domain.com/file.txt-->

it's almost exactly the same as

<? include('/home/user/domain.com/file.txt'); ?>

the only difference is that in first case script includes file only once and then caches it for some time, while with php tag it reads file on each hit.


You can even include file from remote host

<!--INCLUDE_FILE_http://domain.com/file.txt-->


BUT DO NOT DO LIKE THIS

<? include('http://domain.com/file.txt'); ?>


Search Based Related

You get SE hits straight to you galleries you can have "related" based on search query. Check this option under Rotation - Tube - Settings. It's good idea to use this option with Sphinx search.


Sphinx settings

up to update 47 sphinx options were located in includes/config.php, what was a bit uncomfortable. Now you can edit those options nder Rotation - Settings. To seek back- compatibility script first checks includes/config.php and, if it doesnt find any sphinx settings there, checks rotation-settings.


Global Custom Vars

There also some useful global replacements for example for global ads. Take a look at Rotation - Tube - Tpl Custom Vars, adding a variable like "my_var1" gives you tag <!--CUSTOM_VAR_MY_VAR1--> in any template.


Navigation

Some useful additions for <navigation tag
* skip_href_deletion=true by default script deletes href from the link to the current page, with this option - doesnt.
* active_link_style=act_pg and link_style=not_act_page styles for current and other pages

Code: Select all

 
For example

<navigation skip_href_deletion=true active_link_style=act_page link_style=not_act_page>
<li><a href="/?page=<!--PAGE_NUM-->" title="<!--PAGE_NUM-->" class='<!--LINK_STYLE-->' ><!--PAGE_NUM--></a></li>
</navigation>

We have 3 page in total and now on 3nd page

script will output

<li><a href="/?page=1" title="1" class='not_act_page' >1</a></li>
<li><a href="/?page=2" title="2" class='act_page' >2</a></li>
<li><a href="/?page=3" title="3" class='not_act_page' >3</a></li>



w\o skip_href_deletion=true  it will be like 

<li><a href="/?page=1" title="1" class='not_act_page' >1</a></li>
<li>2</li>
<li><a href="/?page=3" title="3" class='not_act_page' >3</a></li>


 

Custom Galleries From ZIP

You can create custom galleries from ZIP files, just point to zip file as gallery URL.

Content type\count

Some galleries have both image, movies and even flash content, that's why 3 more tags were added <!--IMAGE_COUNT-->, <!--MOVIE_COUNT--> и <!--FLASH_COUNT-->.

Reports

Reports were in script long time before but it was a bit separated from script and hardly useful in this way. With this update you'll get report truly integrated in script.

Option 1. in subtemplate, somethere by the thumb add link to report page

Code: Select all

 
Direct link http://domain/scj/tube/?content_id=<!--GALLERY_ID-->&force_template=content_report

or add rewrite

RewriteRule ^report/(.*)/$ /scj/tube/?content_id=$1&force_template=content_report [L] 

and link will be http://domain/report/<!--GALLERY_ID-->/
 
user will get page where he can report a gallery.

Option 2. Right into gallery template (custom_content_pic for example)

Code: Select all

 

<form method="post">
<input type=hidden name="action" value="report">

<font size=+1><b><!--MESSAGE--></b></font>

<h3>Please select the bad link reason and press [Report]</h3>
<font size=-1><b>Note:</b> without the selected <b>reason</b> the report will not be accepted!
<p>

<select name="reason">
<option>please select</option>
<option>not a gallery but unexpected site</option>
<option>description mismatch</option>
<option>dialer</option>
<option>anti-virus program alert</option>
<option>popup window</option>
<option>404 error or Not Found</option>
<option>too slow loading or browser timeout</option>
<option>other reason</option>
</select>
<br>


<input type="submit" name="Submit" value="Report">
</form>
</div>

 

and you'll see report for right on gallery's page , of course this is actual for custom galleries.


For both options you can see reports in Rotation - Tube - Reports.



Sponsor Images

Up to update 48 sponsor's images were saved in scj/gallery/sponsor_images folder. Now it is saved at the same location as you regular thumbs, it's easier to manage all thumbs in 1 folder.


Tube Login Return

When user logins into his account he is being redirected to his favs page. Now you can change this habit if you add return_url=http://... to login form .

Tag Cloud

You can limit output of tag cloud, for example

Code: Select all

 
<tag_cloud order=alphabet num=1-5>
bla-blas
</tag_cloud>

<tag_cloud order=alphabet num=6-10>
bla-blas
</tag_cloud>


 

Trade

Counters & spiders

As you may know a large part of 'blocked_ref' hits is SE bots. Now we have one one separate list of systems trades - counters. Actually it's a kind of dupe traders but traffic of these traders is not included in total stats.

Let's say we've got a hit from trader A, he clicks on a gallery link and we notice that there's no referer. So we add +1 click to trader A and +1 hit to blocked_ref. But in total stats we still have just 1 click.

Another example: SE bot checks your site (we know this is a SE bot by user agent, you can take a look in Settings - config files - spider_ua). Most part of SE bots do not pass referer, but now we count those hits under system trade 'spiders'

And one more example: we've got a hit from trader A and surfer uses iphone. We count +1 hit to trader A and +1 hit to system trade 'mobile'


Trade by groups

If you have a regular multiniche site and you'd like to trade by groups. First of all you have to add something like &group=... to out links but most of webmasters uses rewrite links like /gallery/cool_gal/index.html and if you need a group here you have to change it to something like /gallery/group/cool_gal/index.html but you'll also have to change rewrites and it's hard for most webmasters.

Usually category urls looks like /category/123/asian/ so script can try to detect a group by referer.

What you have to do to use it

- Create trade groups with the same names as rotation groups. You can do it quickly in Rotation - Groups (Copy To Trade Groups)
- Setup groups for traders
- Rotation - CMS - Tube settings turn on 'Niche trade'
- thats all :)


Sell by groups

The same as "Trade by groups", but lets say sell traffic here. We have something like http://brocker.com/?id=your_id in Traffic Rules - Traffic Sell and all sell traffic is being sent to this url. But it would be better if we sell traffic from page /category/japanese/ to http://brocker.com/?id=your_id&niche=japanese caz in this case we cab get higher price.

To do it we add parameter {GROUP} to broker url ( http://brocker.com/?id=your_id&niche={GROUP} ) (an example to trafficholder.com - http://www.trafficholder.com/in/in.php?yourid-{GROUP} ). But if brocker doesnt have niche japanese (lets say the closest one is "tube_asian" ) we have to add in Rotation - CMS - Tube settings some alternatives to "Niche traffic sell" like

tube_asian=Japanese,Asian

where tube_asian - brocker's niches and "Japanese,Asian" - our niches.


[scj_title]

Update 48 released !

New features: Counters and spiders, Models and more[/scj_title]
Don't forget to run script update
Post Reply