Created
September 4, 2024 07:06
-
-
Save tyhallcsu/ed278b7ef56040153924285460636fa0 to your computer and use it in GitHub Desktop.
HTML page with embedded JavaScript that implements the core functionality of the CID converter tool.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>CID Converter Tool</title> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script> | |
<style> | |
body { | |
font-family: Arial, sans-serif; | |
line-height: 1.6; | |
margin: 0; | |
padding: 20px; | |
background-color: #f4f4f4; | |
} | |
.container { | |
max-width: 800px; | |
margin: auto; | |
background: white; | |
padding: 20px; | |
border-radius: 5px; | |
box-shadow: 0 0 10px rgba(0,0,0,0.1); | |
} | |
h1, h2 { | |
color: #333; | |
} | |
input[type="text"], button { | |
width: 100%; | |
padding: 10px; | |
margin-bottom: 10px; | |
} | |
button { | |
background-color: #4CAF50; | |
color: white; | |
border: none; | |
cursor: pointer; | |
} | |
button:hover { | |
background-color: #45a049; | |
} | |
#results { | |
margin-top: 20px; | |
padding: 10px; | |
background-color: #e7e7e7; | |
border-radius: 5px; | |
} | |
</style> | |
</head> | |
<body> | |
<div class="container"> | |
<h1>CID Converter Tool</h1> | |
<p>Enter a CID, FID, or Google Maps URL to convert and generate links.</p> | |
<input type="text" id="input" placeholder="Enter CID, FID, or Google Maps URL"> | |
<button onclick="convertCID()">Convert and Generate Links</button> | |
<div id="results"></div> | |
</div> | |
<script> | |
function convertCID() { | |
const input = $('#input').val().trim(); | |
let cid = extractCID(input); | |
if (!cid) { | |
$('#results').html('<p>Invalid input. Please enter a valid CID, FID, or Google Maps URL.</p>'); | |
return; | |
} | |
const decimalCID = BigInt(cid).toString(10); | |
const hexCID = BigInt(cid).toString(16); | |
const results = ` | |
<h2>Results:</h2> | |
<p><strong>Decimal CID:</strong> ${decimalCID}</p> | |
<p><strong>Hexadecimal CID:</strong> ${hexCID}</p> | |
<p><strong>Google Maps Link:</strong> <a href="https://maps.google.com/?cid=${decimalCID}" target="_blank">https://maps.google.com/?cid=${decimalCID}</a></p> | |
<p><strong>Google Search Link:</strong> <a href="https://www.google.com/search?q=&ludocid=${decimalCID}" target="_blank">https://www.google.com/search?q=&ludocid=${decimalCID}</a></p> | |
`; | |
$('#results').html(results); | |
} | |
function extractCID(input) { | |
// Extract CID from various input formats | |
const cidRegex = /(?:cid=|ludocid=|0x)([0-9a-fA-F]+)/; | |
const match = input.match(cidRegex); | |
return match ? match[1] : null; | |
} | |
</script> | |
</body> | |
</html> |
Update: CID Converter Tool with OSINT Mode
This is an update to the previous CID Converter Tool. The new version includes an OSINT (Open-Source Intelligence) Mode, providing additional information about the business associated with the CID.
New Features:
- OSINT Mode Checkbox: Users can now toggle OSINT Mode on/off.
- Extended Information Display: When OSINT Mode is enabled, the tool displays additional details about the business, including:
- Place ID
- Business Name
- Address
- Phone Number
- Latitude and Longitude
- Link to Google Reviews
- Website
- Social Media Profiles (Facebook, Twitter, Instagram)
Technical Updates:
- Added JavaScript functionality to handle OSINT Mode toggle.
- Implemented a simulated OSINT data object (to be replaced with actual API calls in production).
- Enhanced CSS for better presentation of OSINT results.
Usage:
- Enter a CID, FID, or Google Maps URL in the input field.
- Check the "OSINT Mode" box if you want additional information.
- Click "Convert and Generate Links".
- View the results, including OSINT data if enabled.
Note for Implementation:
The current version uses simulated OSINT data. For a production environment, you should:
- Implement server-side processing for security.
- Use actual APIs or data sources to retrieve OSINT information.
- Add proper error handling and data validation.
- Consider rate limiting and caching for API management.
This update enhances the tool's functionality, making it more useful for those needing comprehensive information about a business based on its CID.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
A basic version of the CID converter tool
I've created a basic HTML page with embedded JavaScript that implements the core functionality of the CID converter tool.
Here's a breakdown of what this tool does:
To use this on your new domain:
cid-converter.html
).http://your-new-domain.com/cid-converter.html
in a web browser.This is a simplified version of the tool. It doesn't include all the features of the original (like the autocomplete field or OSINT mode), but it provides the core functionality. You can expand on this base to add more features as needed.
Some notes: