Skip to content

Commit

Permalink
deploy: 3b2b060
Browse files Browse the repository at this point in the history
  • Loading branch information
rohitd3 committed Jun 5, 2023
1 parent 6e0bc90 commit 9f495c9
Show file tree
Hide file tree
Showing 5 changed files with 153 additions and 333 deletions.
10 changes: 5 additions & 5 deletions assets/css/style.css.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion assets/js/search-data.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

"post0": {
"title": "JavaScript Practice",
"content": "%%html <html> <head> <style> #output { background-color: #f86ddf; padding: 50px; border: 40px solid #1a334f; } </style> </head> <body> <div id="output"> Hello world! </div> </body> </html> . . Hello world! . %%html <html> <head> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script> </head> <style> table { border-collapse: collapse; margin: auto; background-color: black; } th { background-color: black; color: white; padding: 10px; } td { padding: 10px; color: white; } td:nth-child(odd) { background-color: black; } td:nth-child(even) { background-color: black; } tr:nth-child(odd) { background-color: black !important; } tr:nth-child(even) { background-color: black !important; } </style> <body> <table> <tr> <th>Name</th> <th>Planet</th> <th>Species</th> </tr> <tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr> <tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr><tr class = "data-row"></tr> </table> <script> const starwars = { "async": true, "crossDomain": true, "url": "https://star-wars-characters.p.rapidapi.com/46DYBV/star_wars_characters", "method": "GET", "headers": { "X-RapidAPI-Key": "bf09b94566msh22c602dfe97bd97p19c2fajsn1d42e34f8724", "X-RapidAPI-Host": "star-wars-characters.p.rapidapi.com" } }; // object is being intialized and contains //the url, rapid api key and host, method: GET // ajax lets us to load the data without needing to reload the page $.ajax(starwars).done(function (response) { console.log(response); // main method that requests the data from the server for (var i = 0; i < response.length; i++) { // having i < response.length lets me display all // the data but it depends on how much table space I have var newDataName = document.createElement("td"); // where the data will be shown in the data newDataName.innerHTML = response[i].name; var newDataHomeworld = document.createElement("td"); newDataHomeworld.innerHTML = response[i].homeworld; var newDataSpecies = document.createElement("td"); newDataSpecies.innerHTML = response[i].species; $(".data-row").eq(i).append(newDataName) $(".data-row").eq(i).append(newDataHomeworld) $(".data-row").eq(i).append(newDataSpecies) } } ); </script> </body> </html> . . Name Planet Species . . . . . . . . %%html <html> <head> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script> <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.13.3/css/jquery.dataTables.min.css"> <script type="text/javascript" language="javascript" src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> <style> table { border-collapse: collapse; margin: auto; background-color: black; } th { background-color: black; color: white; padding: 10px; } td { padding: 10px; color: white; } td:nth-child(odd) { background-color: black; } td:nth-child(even) { background-color: black; } tr:nth-child(odd) { background-color: black !important; } tr:nth-child(even) { background-color: black !important; } </style> </head> <body> <table id="starWarsTable"> <thead> <tr> <th>Name</th> <th>Planet</th> <th>Species</th> </tr> </thead> <tbody></tbody> </table> <script> $(document).ready(function() { var starWarsAPI = { "async": true, "crossDomain": true, "url": "https://star-wars-characters.p.rapidapi.com/46DYBV/star_wars_characters", "method": "GET", "headers": { "X-RapidAPI-Key": "bf09b94566msh22c602dfe97bd97p19c2fajsn1d42e34f8724", "X-RapidAPI-Host": "star-wars-characters.p.rapidapi.com" } }; # STAR WARS API $.ajax(starWarsAPI).done(function (response) { console.log(response); var table = $('#starWarsTable').DataTable({ data: response, columns: [ { data: 'name' }, { data: 'homeworld' }, { data: 'species' } ] }); $('#starWarsTable thead th').each(function () { var title = $(this).text(); $(this).html('<input type="text" placeholder="Search ' + title + '" />'); }); table.columns().every(function () { var that = this; $('input', this.header()).on('keyup change', function () { if (that.search() !== this.value) { that.search(this.value).draw(); } }); }); }); }); </script> </body> </html> . . Name Planet Species . .",
"content": "%%html <html> <head> <style> #output { background-color: #f86ddf; padding: 50px; border: 40px solid #1a334f; } </style> </head> <body> <div id="output"> Hello world! </div> </body> </html> . . Hello world! . %%html <html> <head> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script> <!-- DataTables CSS --> <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.13.3/css/jquery.dataTables.min.css"> <!-- DataTables JavaScript --> <script type="text/javascript" language="javascript" src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> <style> table { border-collapse: collapse; margin: auto; background-color: black; } th { background-color: black; color: white; padding: 10px; } td { padding: 10px; color: white; } td:nth-child(odd) { background-color: black; } td:nth-child(even) { background-color: black; } tr:nth-child(odd) { background-color: black !important; } tr:nth-child(even) { background-color: black !important; } </style> </head> <body> # Create an empty table with the id "starWarsTable" <table id="starWarsTable"> <thead> <tr> <th>Name</th> <th>Planet</th> <th>Species</th> </tr> </thead> <tbody></tbody> </table> <script> $(document).ready(function() { # Create an object for the Star Wars API request configuration var starWarsAPI = { "async": true, "crossDomain": true, "url": "https://star-wars-characters.p.rapidapi.com/46DYBV/star_wars_characters", "method": "GET", "headers": { "X-RapidAPI-Key": "bf09b94566msh22c602dfe97bd97p19c2fajsn1d42e34f8724", "X-RapidAPI-Host": "star-wars-characters.p.rapidapi.com" } }; # send request to the Star Wars API $.ajax(starWarsAPI).done(function (response) { console.log(response); # DataTable using the response data var table = $('#starWarsTable').DataTable({ data: response, columns: [ { data: 'name' }, // Column 1: Name { data: 'homeworld' }, // Column 2: Planet { data: 'species' } // Column 3: Species ] }); # Add search inputs to each table column header $('#starWarsTable thead th').each(function () { var title = $(this).text(); $(this).html('<input type="text" placeholder="Search ' + title + '" />'); }); # Apply the search functionality for each column table.columns().every(function () { var that = this; $('input', this.header()).on('keyup change', function () { if (that.search() !== this.value) { that.search(this.value).draw(); # event listeners to the search inputs using the .on('keyup change') function. # user types or changes the input, it triggers a search on the corresponding table column # using DataTables' search() function the search is performed dynamically as the user types, and the table is # redrawn to display the filtered results. } }); }); }); }); </script> . . Name Planet Species . </div> </div> </div> </div> </div> </div> .",
"url": "https://rohitd3.github.io/rohitfastpages/javascript/2023/05/21/javascript.html",
"relUrl": "/javascript/2023/05/21/javascript.html",
"date": " • May 21, 2023"
Expand Down
2 changes: 1 addition & 1 deletion feed.xml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="4.1.1">Jekyll</generator><link href="https://rohitd3.github.io/rohitfastpages/feed.xml" rel="self" type="application/atom+xml" /><link href="https://rohitd3.github.io/rohitfastpages/" rel="alternate" type="text/html" /><updated>2023-06-01T12:33:06-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/feed.xml</id><title type="html">rohitd3’s fastpages</title><subtitle>my fastpages lets gooo</subtitle><entry><title type="html">JavaScript Practice</title><link href="https://rohitd3.github.io/rohitfastpages/javascript/2023/05/21/javascript.html" rel="alternate" type="text/html" title="JavaScript Practice" /><published>2023-05-21T00:00:00-05:00</published><updated>2023-05-21T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/javascript/2023/05/21/javascript</id><author><name></name></author><category term="javascript" /><summary type="html"><![CDATA[]]></summary></entry><entry><title type="html">javascript stuff</title><link href="https://rohitd3.github.io/rohitfastpages/collegeboard/2023/05/19/adiJS.html" rel="alternate" type="text/html" title="javascript stuff" /><published>2023-05-19T00:00:00-05:00</published><updated>2023-05-19T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/collegeboard/2023/05/19/adiJS</id><author><name></name></author><category term="collegeboard" /><summary type="html"><![CDATA[Javascrpit]]></summary></entry><entry><title type="html">JavaScript Tutorial</title><link href="https://rohitd3.github.io/rohitfastpages/techtalk/javascript" rel="alternate" type="text/html" title="JavaScript Tutorial" /><published>2023-05-11T00:00:00-05:00</published><updated>2023-05-11T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/techtalk/javascripttutorial</id><author><name></name></author><category term="C4.0" /><summary type="html"><![CDATA[Quick launch into Variables, Functions, Arrays, Classes, HTML.]]></summary></entry><entry><title type="html">FRQ 2017 Running Code</title><link href="https://rohitd3.github.io/rohitfastpages/java/2023/04/27/frqpractice2017.html" rel="alternate" type="text/html" title="FRQ 2017 Running Code" /><published>2023-04-27T00:00:00-05:00</published><updated>2023-04-27T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/java/2023/04/27/frqpractice2017</id><author><name></name></author><category term="java" /><summary type="html"><![CDATA[Reviewed by Nathan Shih]]></summary></entry><entry><title type="html">Hacks Unit 5,9,10 - Rohit, Nathan, Jun</title><link href="https://rohitd3.github.io/rohitfastpages/java/2023/04/26/labhacks.html" rel="alternate" type="text/html" title="Hacks Unit 5,9,10 - Rohit, Nathan, Jun" /><published>2023-04-26T00:00:00-05:00</published><updated>2023-04-26T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/java/2023/04/26/labhacks</id><author><name></name></author><category term="java" /><summary type="html"><![CDATA[]]></summary></entry></feed>
<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="4.1.1">Jekyll</generator><link href="https://rohitd3.github.io/rohitfastpages/feed.xml" rel="self" type="application/atom+xml" /><link href="https://rohitd3.github.io/rohitfastpages/" rel="alternate" type="text/html" /><updated>2023-06-05T04:52:32-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/feed.xml</id><title type="html">rohitd3’s fastpages</title><subtitle>my fastpages lets gooo</subtitle><entry><title type="html">JavaScript Practice</title><link href="https://rohitd3.github.io/rohitfastpages/javascript/2023/05/21/javascript.html" rel="alternate" type="text/html" title="JavaScript Practice" /><published>2023-05-21T00:00:00-05:00</published><updated>2023-05-21T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/javascript/2023/05/21/javascript</id><author><name></name></author><category term="javascript" /><summary type="html"><![CDATA[]]></summary></entry><entry><title type="html">javascript stuff</title><link href="https://rohitd3.github.io/rohitfastpages/collegeboard/2023/05/19/adiJS.html" rel="alternate" type="text/html" title="javascript stuff" /><published>2023-05-19T00:00:00-05:00</published><updated>2023-05-19T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/collegeboard/2023/05/19/adiJS</id><author><name></name></author><category term="collegeboard" /><summary type="html"><![CDATA[Javascrpit]]></summary></entry><entry><title type="html">JavaScript Tutorial</title><link href="https://rohitd3.github.io/rohitfastpages/techtalk/javascript" rel="alternate" type="text/html" title="JavaScript Tutorial" /><published>2023-05-11T00:00:00-05:00</published><updated>2023-05-11T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/techtalk/javascripttutorial</id><author><name></name></author><category term="C4.0" /><summary type="html"><![CDATA[Quick launch into Variables, Functions, Arrays, Classes, HTML.]]></summary></entry><entry><title type="html">FRQ 2017 Running Code</title><link href="https://rohitd3.github.io/rohitfastpages/java/2023/04/27/frqpractice2017.html" rel="alternate" type="text/html" title="FRQ 2017 Running Code" /><published>2023-04-27T00:00:00-05:00</published><updated>2023-04-27T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/java/2023/04/27/frqpractice2017</id><author><name></name></author><category term="java" /><summary type="html"><![CDATA[Reviewed by Nathan Shih]]></summary></entry><entry><title type="html">Hacks Unit 5,9,10 - Rohit, Nathan, Jun</title><link href="https://rohitd3.github.io/rohitfastpages/java/2023/04/26/labhacks.html" rel="alternate" type="text/html" title="Hacks Unit 5,9,10 - Rohit, Nathan, Jun" /><published>2023-04-26T00:00:00-05:00</published><updated>2023-04-26T00:00:00-05:00</updated><id>https://rohitd3.github.io/rohitfastpages/java/2023/04/26/labhacks</id><author><name></name></author><category term="java" /><summary type="html"><![CDATA[]]></summary></entry></feed>
Loading

0 comments on commit 9f495c9

Please sign in to comment.