Problems with html directory on google sites

Asked

Viewed 197 times

0

How to put HTML image from any PC folder?

Google Sites has the option to embed snippets of html code on their site, usually (as far as I know) css and js are embedded in separate files, but google forces you to use tags like and in html to implement these snippets in another language.

I’m trying to incorporate an image carousel (html, js, css) in Google sites, the code is ready and works but when I try to embed in the site html can not find the images that will be used.

After a quick search, I understood that html is not able to access images that are not in the same directory as the file. I have no idea where is the directory that the html embedded in google is saved, IE, I do not know where to put these images.

<html>
	<header> 
		<title>Home Page</title>

		<style type="text/css">
			código css
		</style>

	
	</header>
	
	<body >	
	
		<div id="carrossel">
			<img id="prev" src="./assets/back.png" alt="left">
			<div id="itens">
				<ul>
					<li>
						<div class="item"><img id="1" src="./assets/unnamed (1).png" alt="imagem 1">
						</div>
					</li>
					

					<li>
						<div class="item">
							<img id="2" src="./assets/unnamed.png" alt="imagem 2">
						</div>
					</li>

				
					<li>
						<div class="item">
							<img id="3" src="./assets/unnamed.jpg" alt="imagem 3">
						</div>
					</li>

				</ul>
			</div>
			<img id="next" src="./assets/back.png" alt="right"  >	
			

		</div>

		<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js">
		</script>

		<script >{
		código js
		</script>
		
	</body>
</html>

My question is whether html really can’t access files from different directories, and how would it be possible to get around this with the use of another language.

1 answer

0

Google sites

From what I saw on Google sites have an option of images there, already tried to click there to see if it works?

  • This image option is only to place an image on the screen, this image can be loaded from the computer, from a bank provided by Google or taken directly from the web. It is possible to add a link and caption to this image, but not to reference it in html code, because it is saved in the cloud and in this case is necessarily used as button/illustration. What I try here is to figure out how to call an image via html from any folder or correctly adapt the image address in the code.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.