{"id":308255,"date":"2026-06-25T03:04:29","date_gmt":"2026-06-25T03:04:29","guid":{"rendered":"https:\/\/digitalmarketstore.com\/?page_id=308255"},"modified":"2026-06-25T03:12:16","modified_gmt":"2026-06-25T03:12:16","slug":"safelist-control-hub","status":"publish","type":"page","link":"https:\/\/digitalmarketstore.com\/safelist-control-hub\/","title":{"rendered":"Safelist Control Hub"},"content":{"rendered":"<p><!-- First-time info box --><\/p>\n<div style=\"padding:15px; background:#eef7ff; border:1px solid #bcd7f0; margin-bottom:20px; border-radius:6px;\">\n  <strong>First Time Using This Tool?<\/strong><\/p>\n<p>  If this is your first time using the tool, you don\u2019t need to upload anything. Just add your entries and download your sheet when you\u2019re done. When you return later, upload your saved sheet to continue where you left off.\n<\/p><\/div>\n<p><!-- Safelist Credit Tracker App --><\/p>\n<div id=\"safelist-app\">\n<h2>Safelist Credit Tracker<\/h2>\n<p><strong>Optional:<\/strong> Upload your existing CSV (website, username, password, credits)<\/p>\n<p>  <input type=\"file\" id=\"fileInput\" accept=\".csv\" \/><\/p>\n<p style=\"margin-top:10px;\"><strong>When finished:<\/strong> Click below to download your updated sheet and save it.<\/p>\n<p>  <button onclick=\"downloadCSV()\">Download Updated CSV<\/button><\/p>\n<h3 style=\"margin-top:20px;\">Add New Entry<\/h3>\n<p>  <input id=\"newWebsite\" placeholder=\"Website URL\"><br \/>\n  <input id=\"newUser\" placeholder=\"Username\"><br \/>\n  <input id=\"newPass\" placeholder=\"Password\"><br \/>\n  <input id=\"newCredits\" placeholder=\"Credits\"><br \/>\n  <button onclick=\"addEntry()\">Add Entry<\/button><\/p>\n<h3 style=\"margin-top:20px;\">Your Safelist Accounts<\/h3>\n<table border=\"1\" id=\"dataTable\" cellspacing=\"0\" cellpadding=\"5\">\n<thead>\n<tr>\n<th>Website<\/th>\n<th>Username<\/th>\n<th>Password<\/th>\n<th>Credits<\/th>\n<th>Log In (Web)<\/th>\n<th>Delete<\/th>\n<\/tr>\n<\/thead>\n<tbody><\/tbody>\n<\/table>\n<\/div>\n<p><script>\nlet entries = [];<\/p>\n<p>\/\/ Handle CSV upload (optional)\ndocument.getElementById(\"fileInput\").addEventListener(\"change\", function(e) {\n  const file = e.target.files[0];\n  if (!file) return;<\/p>\n<p>  const reader = new FileReader();\n  reader.onload = function(event) {\n    parseCSV(event.target.result);\n    renderTable();\n  };\n  reader.readAsText(file);\n});<\/p>\n<p>\/\/ Parse CSV: website, username, password, credits, (optional) login_formula\nfunction parseCSV(csv) {\n  const lines = csv.split(\"\\n\").map(l => l.trim()).filter(l => l.length);\n  entries = [];\n  if (lines.length <= 1) return;\n\n  for (let i = 1; i < lines.length; i++) {\n    const cols = splitCSVLine(lines[i]);\n    entries.push({\n      website:  cols[0] || \"\",\n      username: cols[1] || \"\",\n      password: cols[2] || \"\",\n      credits:  cols[3] || \"\"\n    });\n  }\n}\n\n\/\/ Simple CSV splitter (handles quoted commas)\nfunction splitCSVLine(line) {\n  const result = [];\n  let cur = \"\";\n  let inQuotes = false;\n\n  for (let i = 0; i < line.length; i++) {\n    const c = line[i];\n    if (c === '\"' ) {\n      if (inQuotes &#038;&#038; line[i+1] === '\"') {\n        cur += '\"';\n        i++;\n      } else {\n        inQuotes = !inQuotes;\n      }\n    } else if (c === ',' &#038;&#038; !inQuotes) {\n      result.push(cur);\n      cur = \"\";\n    } else {\n      cur += c;\n    }\n  }\n  result.push(cur);\n  return result;\n}\n\n\/\/ Render table\nfunction renderTable() {\n  const tbody = document.querySelector(\"#dataTable tbody\");\n  tbody.innerHTML = \"\";\n\n  entries.forEach((e, index) => {\n    const loginUrl = generateLoginURL(e.website, e.username, e.password);<\/p>\n<p>    const row = document.createElement(\"tr\");\n    row.innerHTML = `<\/p>\n<td>${escapeHtml(e.website)}<\/td>\n<td>${escapeHtml(e.username)}<\/td>\n<td>${escapeHtml(e.password)}<\/td>\n<td>${escapeHtml(e.credits)}<\/td>\n<td>${loginUrl ? `<a href=\"${loginUrl}\" target=\"_blank\">Log In<\/a>` : \"\"}<\/td>\n<td><button onclick=\"deleteEntry(${index})\">Delete<\/button><\/td>\n<p>    `;\n    tbody.appendChild(row);\n  });\n}<\/p>\n<p>\/\/ Add entry\nfunction addEntry() {\n  const website  = document.getElementById(\"newWebsite\").value.trim();\n  const username = document.getElementById(\"newUser\").value.trim();\n  const password = document.getElementById(\"newPass\").value.trim();\n  const credits  = document.getElementById(\"newCredits\").value.trim();<\/p>\n<p>  if (!website || !username || !password) {\n    alert(\"Website, username, and password are required.\");\n    return;\n  }<\/p>\n<p>  entries.push({ website, username, password, credits });\n  renderTable();<\/p>\n<p>  document.getElementById(\"newWebsite\").value = \"\";\n  document.getElementById(\"newUser\").value = \"\";\n  document.getElementById(\"newPass\").value = \"\";\n  document.getElementById(\"newCredits\").value = \"\";\n}<\/p>\n<p>\/\/ Delete entry\nfunction deleteEntry(index) {\n  entries.splice(index, 1);\n  renderTable();\n}<\/p>\n<p>\/\/ Generate login URL (customize per safelist if needed)\nfunction generateLoginURL(site, user, pass) {\n  if (!site) return \"\";\n  \/\/ Example customization:\n  \/\/ if (site.includes(\"herculist\")) {\n  \/\/   return site + \"\/login?user=\" + encodeURIComponent(user) +\n  \/\/          \"&pass=\" + encodeURIComponent(pass);\n  \/\/ }\n  return site; \/\/ default: just open the site\n}<\/p>\n<p>\/\/ Download CSV with Google Sheets HYPERLINK formula column\nfunction downloadCSV() {\n  let csv = \"website,username,password,credits,login_formula\\n\";<\/p>\n<p>  entries.forEach(e => {\n    const loginUrl = generateLoginURL(e.website, e.username, e.password);\n    const formula = loginUrl\n      ? `=HYPERLINK(\"${loginUrl.replace(\/\"\/g, '\"\"')}\", \"Log In\")`\n      : \"\";<\/p>\n<p>    const row = [\n      e.website || \"\",\n      e.username || \"\",\n      e.password || \"\",\n      e.credits || \"\",\n      formula\n    ].map(v => `\"${(v + \"\").replace(\/\"\/g, '\"\"')}\"`).join(\",\");<\/p>\n<p>    csv += row + \"\\n\";\n  });<\/p>\n<p>  const blob = new Blob([csv], { type: \"text\/csv\" });\n  const url = URL.createObjectURL(blob);\n  const a = document.createElement(\"a\");\n  a.href = url;\n  a.download = \"safelist_accounts_with_login_buttons.csv\";\n  a.click();\n  URL.revokeObjectURL(url);\n}<\/p>\n<p>\/\/ Escape HTML\nfunction escapeHtml(str) {\n  if (!str) return \"\";\n  return str\n    .replace(\/&\/g, \"&amp;\")\n    .replace(\/<\/g, \"&lt;\")\n    .replace(\/>\/g, \"&gt;\")\n    .replace(\/\"\/g, \"&quot;\")\n    .replace(\/'\/g, \"&#039;\");\n}\n<\/script><\/p>\n","protected":false},"excerpt":{"rendered":"<p>First Time Using This Tool? If this is your first time using the tool, you don\u2019t need to upload anything. Just add your entries and download your sheet when you\u2019re done. When you return later, upload your saved sheet to continue where you left off. Safelist Credit Tracker Optional: Upload your existing CSV (website, username, [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"order-bump-settings":[],"_wpfnl_thankyou_order_overview":"on","_wpfnl_thankyou_order_details":"on","_wpfnl_thankyou_billing_details":"on","_wpfnl_thankyou_shipping_details":"on","footnotes":""},"class_list":["post-308255","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/digitalmarketstore.com\/v\/wp\/v2\/pages\/308255","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/digitalmarketstore.com\/v\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/digitalmarketstore.com\/v\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/digitalmarketstore.com\/v\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/digitalmarketstore.com\/v\/wp\/v2\/comments?post=308255"}],"version-history":[{"count":2,"href":"https:\/\/digitalmarketstore.com\/v\/wp\/v2\/pages\/308255\/revisions"}],"predecessor-version":[{"id":308258,"href":"https:\/\/digitalmarketstore.com\/v\/wp\/v2\/pages\/308255\/revisions\/308258"}],"wp:attachment":[{"href":"https:\/\/digitalmarketstore.com\/v\/wp\/v2\/media?parent=308255"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}