====== How to use the script for posting to TGP ====== You can easily post galleries to TGP for additional traffic. Here's why this approach works well: - If you already have custom galleries, you can immediately post them to TGP - For those just doing TGP posting, this method manages content effectively - You can quickly create galleries from sponsor zip archives ([[http://smartcj.com/wiki/doku.php?id=ru:update_48#custom_galleries_from_zip]]) **Important points for posting to TGP:** - Gallery code should not change at all - Different recipes are needed for different TGPs **How to set it up:** * Create a custom template in Rotation - CMS Pages (for example, `tgp_pic`) with no related galleries — only the gallery's own thumbnails. Avoid related galleries since they change, and you need the gallery to remain static. * Add code like this to the template: recipes 1 here recipes 2 here Add as many recipe blocks as needed. Also remove the rot_in and scj_include tags from this template, since they can change. * Add a rewrite rule to the end of .htaccess (or your nginx config): RewriteRule ^gallery/([^/]+)/recip_([^\.]+).html$ /scj/tube/?slug=$1&force_template=tgp_pic&recip=$2 [L] * Gallery links will look like this: http://domain/gallery//recip_1.html http://domain/gallery//recip_2.html Where 1, 2, etc. represent the recipes. You can replace these numbers with TGP names if preferred. **How to generate this URL format** There's no dedicated section for recipe URLs, but you can go to Rotation - Export and select "Slug URL" in any pattern field. The script will generate URLs like: http://domain/gallery/cool_gal/index.html Then replace `index.html` with `recip_1.html`, `recip_2.html`, etc. using any text editor or during your TGP posting process.