guys I'm supposed to upload assignment for this online course..
I followed the tutorial along exactly but something is not working properly.
https://zwc1625.github.io/coursera-web24/ is the where my repo is published and it's working fine.
but,
https://zwc1625.github.io/coursera-web24/mod_2/
where mod_2 is the assignment folder containing 1 html and 1 css file,
when I try to type in this address in the url 404 comes up
My local drive is up to date with the github repo
Help. New and very frustrated with github, I'm spending so much time with this and making no progress.
Github will serve a few specifically named files automatically, like 'index.html', 'readme.md' or 'readme'. Most servers will look in the specified folder (https://zwc1625.github.io/coursera-web24/mod_2/) for files named: 'index' or 'default' with a specific extension like 'html', 'asp', 'xhtml'.
As the file in your folder 'mod_2' is called 'module2HTML.html' it will not get served automatically. Consequently, if you want to open that file in your browser, you will need to name it specifically in the URL you enter in the browser addressbar: https://zwc1625.github.io/coursera-web24/mod_2/module2HTML.html
Furthermore, when you did name your file 'index.html' it may be possible that there is a time lag between your 'commit' and Github being able to serve your page. Some patience may be required....
Related
I am trying to find the best way to host a bunch of pdfs(and other files potentially) on my synology DS1821+ that can be accessed by a URL so employees can access them by scanning a QR code. The files should be available to any device connected to our WiFi.
I was able to achieve this quite easily using WordPress and simply uploading the files to the "Media Library" And converting the URL to QR code using my web browser.
Here is an example of one of the URLs provided:
http://10-0-1-128.synologynas.direct.quickconnect.to/wordpress/wp-content/uploads/2022/10/F09042-fix.pdf
this also works:
http://10.0.1.128/wordpress/wp-content/uploads/2022/10/F09042-fix.pdf
However, since we would be printing potentially thousands of QR codes to be used around the factory for years to come I need the URL to be something I can control manually, without stuff like "2022" in it so that if someday we switch to different software/hardware we can replicate the same structure so as not to need to reprint and redistribute thousands of QR codes.
I see the application "File Station" on my NAS and this is close to what I want but not quite. There I can right click a file -> share ->QR code and it returns something like this:
http://gofile.me/73nWA/C8AYNuBpv
Pretty cool, but again the URL is not something I can control, and also it uses some advanced voodoo to make the link work anywhere on the internet and these need to only work on our local network.
Any thoughts on the simplest way to achieve wat I'm looking for?
-Thanks
Edit -
I see now that I can add a folder to the "web" directory using File Station, and then add files to that folder and access them in my web browser by going to:
/folder/filename.pdf - (although if I right click it and say open in new tab it access it through a long and convoluted url???)
which is basically what I wanted
however, I would like to be able to also go to:
/folder
and see a selectable list of all the files as well
I know I can create I link by adding something like
<a href="file.pdf" etc etc etc
to the .html file, but I'm working with about potentially thousands of files.
Is there a way to just generate one for every file in the folder.
as I'm sure you can tell I'm a noob at this.
Figured it out.
As long as you have some web server SW up and running you should be able to acces files placed in the /web folder of the "file station." for example if there is a pdf in the web folder named document.pdf you can access it by going to /document.pdf in your browser on local network.
If there is a folder name named pdf with files in it in the /web folder
you can add index.php to that folder with the following code in it to see a list of links to the files in it in your web browser.
<?php
$dir = "/volume1/web/pdf";
// Open a directory, and read its contents
if (is_dir($dir)){
if ($dh = opendir($dir)){
while (($file = readdir($dh)) !== false){
echo " <a href=./$file>$file</a><br>";
}
closedir($dh);
}
}
?>
TLDR: GitHub Pages isn't working.
I have a little knowledge on GitHub and tried multiple fixes to no avail. One repository is only showing readme file contents.
Please explain in lamest terms.
New to web development, I finally was able to complete my first site, but I'm unable to actually deploy the files for some reason; please forgive me, I literally have no idea what any of the git terminologies are.
I purchased a pro subscription in order to keep the repository private and the site public.
Every file is present in what seems to be the main root directory, but nothing is being actually presented.
I've created two different repositories in an effort to fix this, as I've seen different methods are available.
The first repository includes a README file because I was originally instructed to do so, however, all the site link does is present that README file's contents;
I also attempted to add a permalink fix within the file, but all it did was add that text to the other text presented.
The second repository in question literally greets me with nothing but a 404 error.
The solution I tried for the second repository was to have the repository name share my username as well since that seems to be where the site's link originates, but no present changes have occurred.
Finally, the waiting game solution hasn't beared any fruit yet either aside from updating the README file's contents.
All help is very much appreciated.
Check first:
Your GitHub repository name, which depends on the type of GitHub Pages you are creating
If you're creating a user or organization site, your repository must be named <user>.github.io or <organization>.github.io.
your GitHub Pages Publishing source
If you use the default publishing source for your GitHub Pages site, your site will publish automatically. You can also choose to publish your site from a different branch or folder.
You can add more pages to your site by creating more new files.
Each file will be available on your site in the same directory structure as your publishing source.
For example, if the publishing source for your project site is the gh-pages branch, and you create a new file called /about/contact-us.md on the gh-pages branch, the file will be available at https://<user>.github.io/<repository>/about/contact-us.html.
Make sure you have GitHub Pages enabled for every repository and that it's set to the branch you want to publish by checking your Pages settings at github.com/<user>/<repo>/settings/pages. If enabled, there should be a link on that page that takes you to the site.
This is my first time using Gitlab.
My repository url is myusername.gitlab.io/myrepo.
Opening that page gives me a 404 error, however when I open myusername.gitlab.io/myrepo/myindex.html, I get my index page.
Can someone tell me how I can set it so myusername.gitlab.io/myrepo loads myusername.gitlab.io/myrepo/myindex.html.
On a second note, I have seen other projects that use username.gitlab.iowithout the need for the/therepo` suffix.
Can anyone tell me how I can remove the suffix and just use the domain to access my repo.
Your server may prefer a default 'index' file to be loaded. In some cases, it may not handle the default file at all.
Rename you index file from myindex.html to index.html
First, to start, you can fork a pre-set project, with the right files in it (including an index.html): see gitlab.com/pages for examples, and "Getting started" for the steps
.
I really want to have myusername.github.io only
Second, that is a user website: make sure your repo (where you have forked/cloned the project example) is named after your GitLab login: <you>.gitlab.io.
I'm trying to set-up a github page with a name scheme of 'orgname.github.io'. In my case, I named my repository with "natoursqm.github.io" but I still get this '404 There isn't a GitHub Pages site here." error and I don't know how will I fix this problem, I've been quite searching for answers here but most of them used a 'username.github.io' name scheme.
Your page will have to be the name of your GitHub username.
So in your current case, you would need to have a repo like this:
quizonmarielle.github.io
Otherwise you'll have to create a new GitHub account with the username "natoursqm" to create a GitHub page called
natoursqm.github.io
Also wanted to note that the GitHub page HAS to be in this format
your_username.github.io
it cannot have anything extra with the username
Take a look at my github portfolio.
https://sujithnath.github.io/sujithnath/
the URL should end with your repo name. here it is nothing but sujithnath
You have to configure from you repo settings.
You can read more # https://pages.github.com/
How do I find the filename of an website I am inspecting with Firebug? As example when I look on http://example.org/ I can view inspect the Element, I see the whole html structure but I didn`t find the filename. I am searching for index.html or something in that way. Maybe this is an analog question, but I am not sure, because he/she is working with php. LINK
I know there are some solutions with Dreamweaver or other tools but I am searching for an easy way to figure that out with Firebug or an free Browser Add-On. I Hope you have a solution for that.
The URL you entered is the one that usually returns the main HTML contents. Though on most pages nowadays the HTML is altered using JavaScript. Also, pages are very often dynamically generated on the server.
So, in most cases there is no static .html file.
For what it's worth, you can see all network requests and their responses within Firebug's Net panel.
Note that the URL path doesn't necessarily reflect a file path on the server's file system. It is depending on the server configuration, where a specific URL maps to in the file system. The simplest example is the index file that is automatically called when a domain is accessed. In the case of http://example.org the server automatically loads a file index.html in the file system, for example.
So, in order to get the file name on the file system, you need to either check the server configuration or the related access logs.