The Only World-Standard SEO Software

SEO and Internet Marketing Forum
Welcome, Guest ( Login | Register )

Customizing CSV/TXT Export Template
New Topic Add Reply
Page 1 of 1 [ 3 posts ]
Author Message
aaron.cediel

Newborn

Newborn
Posts: 1
Posted: Fri Aug 26, 2016 10:34 am

Hi,

I have been trying to write a customized CSV/TXT Export Template for Rank Tracker (RT) but I have great difficulty to finish the script. I am quite a decent amateur programmer and have managed to take the native RT export template apart, thereby constructing a historic report that serves me just fine.

However, the greatest problem is not the coding language, but the missing documentation on what variables are available to code with. I have been working on this for a couple of days now and have reach wits end. Could anyone from RT-Support-Team or Forum Member help me?

My need:
Convert the code from historic data to display only the last available record/position.

My Code:
Code:
<[DEFINE name="dateFormat" value="exportData.createDateFormat('yyyy-MM-dd')"/]>
<[DEFINE name="keywords" value="exportData.keywords"/]>
<[DEFINE name="searchEngines" value="exportData.searchEngines"/]>
<[DEFINE name="competitors" value="exportData.competitors"/]>
<[DEFINE name="ENTERED_VALUE" value="2147483647"/]>
<[DEFINE name="DROPPED_VALUE" value="-2147483646"/]>
<[DEFINE name="NOT_RANKED_VALUE" value="-2147483647"/]>
<[DEFINE name="NOT_CHECKED_VALUE" value="-2147483648"/]>
Date,Keyword,Search Engine,Site,Rank,URL
<[FOR_EACH name="keywords" id="keyword"]><[FOR_EACH name="searchEngines" id="searchEngineType"]><[DEFINE name="history" value="keyword.getHistory(searchEngineType)"/]><[FOR_EACH name="exportData.reverse(history)" id="historyRecord"]>"<[ECHO text="dateFormat.format(historyRecord.checkDate)"/]>",<[ECHO text="keyword.query"/]>,<[ECHO text="searchEngineType.getName()"/]>,<[ECHO text="exportData.getProject().getDomain()"/]>,<[DEFINE name="position" value="exportData.getPosition(historyRecord)"/]><[IF condition="position != null"]><[THEN]><[ECHO text="position"/]><[/THEN]><[/IF]>,<[ECHO text="historyRecord.url"/]>
<[FOR_EACH name="competitors" id="competitor"]>"<[ECHO text="dateFormat.format(historyRecord.checkDate)"/]>",<[ECHO text="keyword.query"/]>,<[ECHO text="searchEngineType.getName()"/]>,<[ECHO text="competitor.getShortName()"/]>,<[DEFINE name="competitorHistoryRecord" value="exportData.getKeywordPosition(competitor, keyword, searchEngineType, historyRecord)"/]><[IF condition="competitorHistoryRecord != null"]><[THEN]><[DEFINE name="position" value="exportData.getPosition(competitorHistoryRecord)"/]><[IF condition="position != null"]><[THEN]><[ECHO text="position"/]><[/THEN]><[/IF]><[/THEN]><[/IF]>,<[DEFINE name="competitorHistoryRecord" value="exportData.getKeywordPosition(competitor, keyword, searchEngineType, historyRecord)"/]><[IF condition="competitorHistoryRecord != null"]><[THEN]><[ECHO text="competitorHistoryRecord.url"/]><[/THEN]><[/IF]>
<[/FOR_EACH]><[/FOR_EACH]><[/FOR_EACH]><[/FOR_EACH]> 

The code produces a table with the following columns, which should be the same for the "last-entry-only"-export template:
  1. Date: date formated as yyyy-MM-dd e.g. 2016-08-26
  2. Keyword
  3. Search Engine
  4. Site: project/competitor-domain e.g. example.com
  5. Rank: i.e. Position
  6. URL: e.g. http://www.example.com/folder/page.html
Thanks you for any help you could provide!
Aaron :)

P.S. Also, if anyone could indicate a link or provide a list of the available variables and parameters for RT - that would be a great step forward for everyone in a similar situation.

AndyGWood

Newborn

Newborn
Posts: 2
Posted: Sun Mar 26, 2017 3:25 am

I've seen more than one request for a variables list. Many users that purchase this software will be technical, I don't know why a variables list for each piece of software isn't released with the enterprise version. Creating custom forms, while a great feature in theory, is extremely cumbersome in it's current state.

Also, I had to reinstall SEO powersuite, and I had hours and hours of time spent creating custom templates. After install, they are all gone. Anyone know how to recover?

Andrew

oscarneto

Newborn

Newborn
Posts: 2
Posted: Thu Jan 02, 2020 8:23 pm

Hello Aaron, how are you?

Could you find any solution to extract only the latest rankings? I have the same scenario here and could not evolve = (

Thank you for your help!

Display topics from previous:    Sort by    
New Topic Add Reply
Page 1 of 1 [ 3 posts ]
All times are UTC

Jump to:  


cron