fantasma 0 Junior Poster in Training

Greetings!

I'm at the moment stuck with something that would be very trivial, but, since I'm not that versed in jQuery and Zepto I can't figure out a way to solve it.

I need to animate a slider

With jQuery everything works fine

$('.slider').animate({
    left: '-=1024px'
    },500);
}

But with Zepto, as it doesn't supports the '+=' property, it only slides the first two images!

$('.slider').anim({
    translate3d: '-1024px,0px,0px'
},1,'linear');
}

Can I have some help / directions ?

Thank you!

fantasma 0 Junior Poster in Training

Thank you for your reply

That generaly works, but, the file is generated by the InDesign, and I would want a more direct generation, without having the trouble of replacing the quotes manually .

I don't know, but the quotes are "static" in the script, the ones which come with the generated text are escaped, and don't really matter for the "equation".

Unfortunately, the "no simple solution" idea persists :(

fantasma 0 Junior Poster in Training

So what should I do?

I've already changed the code editor to UTF-8 but the problem still persists

Note: This isn't a webpage code, but an Adobe InDesign script I've coded

fantasma 0 Junior Poster in Training

Graphics, with those replacement arguments, not even the first line is replaced!! :(

fantasma 0 Junior Poster in Training

Hello Troy.

Believe me when I say it does! ;)

fantasma 0 Junior Poster in Training

Hello

I'm trying to generate a JSON file with the JSON.Stringify, but, the quotes that are generated by my code o are not compliant with the json format. It's generating smart quotes to the left like (“object”:“pair”) instead of ("object":"pair")

Does anybody knows how to solve this? I've searched dozens of articles but none was clear or worked

So far I've tried this pieces of code

//myObject is a string

myObject = myObject.replace('”','\u0022');
myObject = myObject.replace('“','\u0022');

myObject = myObject.replace('”','\"');
myObject = myObject.replace('“','\"');


myObject = myObject.replace('”','"');
myObject = myObject.replace('“','"');

myObject = myObject.replace('\u201C', '\u0022');
myObject = myObject.replace('\u201D', '\u0022');

But none seems to work

Glad for all the help I can have on this

fantasma 0 Junior Poster in Training

Anyone can help me please? I really needed this working

fantasma 0 Junior Poster in Training

Greetings

I've got this code that tries to update a sortable list (not really a list since I don't use ordered lists, but divs). The thing is, I tested in another area of my site and it's working fine. When moving forward to another list, it just doesn't seem to work at all...

This is the code that is working

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.6/jquery-ui.js"></script>

<script>
$(document).ready(
function() {
$("#cont_etiquetas").sortable({
	update : function () {
	serial = $('#cont_etiquetas').sortable('serialize');
	$.ajax({
	url: "../includes/updateList.php?mod=noticias",
	type: "post",
	data: serial,
	error: function(){
	alert("theres an error with AJAX");
}
});
}
});
}
);

This is a working example of my HTML/PHP code

<div id="cont_etiquetas">

		<?php 
		
		
		$sentence = "SELECT * FROM $table ORDER BY sort ";
		$query = mysql_query($sentence);
		if(!$query)
		{
			echo "Erro ao executar a query".mysql_error();
		}
		while ($row = mysql_fetch_array($query)){
		
		$titulo=$row['titulo_noticia'];
		$id=$row['ID'];
		$descricao = $row['corpo_noticia'];
		$data_adic = $row['data'];
		
		
		echo'<div class="etiquetas" id="menu_'.$id.'">';
		
		
				echo '<div class="tit_etiq">';
					echo $titulo;
				echo'</div>';
		
		echo'<div class="botoes_comando">
					
					<a href="#"><div class="visualiza" id="visualiza"></div></a>
					<a href="#" onClick="show3()"><div class="edita"></div></a>
					<a href="../crud/delete.php?id='.$id.'&mod='.$table.'" onclick="return show_confirm()"><div class="elimina" id="delete"></div></a>
					<a href="#" onClick="show()"><div class="upimagem"></div></a>
				</div>';
				
				
			echo '</div>';

And here are the non-working examples

jQuery

<script>
$(document).ready(
function() {
$("#container_submenu").sortable({
	update : function () {
	serial = $('#container_submenu').sortable('serialize');
	$.ajax({
	url: "../includes/updateList.php",
	type: "post",
	data: serial,
	error: function(){
	alert("theres an error with AJAX");
}
});
}
});
});
</script>
$sentence = "SELECT menu.ID, menu.titulo, menu.id_modulo FROM menu, modulos WHERE menu.id_modulo = modulos.id_modulo AND modulos.nome_mod='Servicos' ORDER BY sort";

		
		$query = mysql_query($sentence);
		if(!$query)
		{
			echo "Erro ao executar a query".mysql_error();
		}
		echo …
fantasma 0 Junior Poster in Training

You said: "The croped image on server appears correctly".
When displayed with what and from where?

It's correctly cropped yes. I know it because, the new images I downloaded come with correct width and height, appearing as a single image, not in a repeated way.

In the server, I save the original image, and 2 cropped images. One for the slideshow, and one thumb with smaller dimensions. This one is displayed correctly

fantasma 0 Junior Poster in Training

chrishea, thank you for your reply.

The thing is, i'm not displaying images with css. I'm just printing the <img> tags with PHP.

Here's the code that does it

<?php 

			
					$sentence = "SELECT imagens.caminho, noticias.ID as idnot, noticias.titulo_noticia FROM imagens, noticias WHERE noticias.ID_IMG = imagens.ID ORDER BY noticias.data DESC";

					
					$query = mysql_query($sentence);
					if(!$query)
					{
						echo "Erro ao executar a query".mysql_error();
					}
					while ($row = mysql_fetch_array($query)){
					
					$caminho = $row['caminho']; //Path to the image on server
					$id_not = $row['idnot']; //News id
					$titulo_not = $row['titulo_noticia'];
					
					echo'<a href="noticias.php?id_not='.$id_not.'">';
				
					echo'<img src="'.$caminho.'"/>';
					echo'<span>';
					echo $titulo_not;
					echo'</span>';

					echo'</a>';
					echo'<div class="SliderName_2Description_h"></div>';
					
					
					}
					?>
fantasma 0 Junior Poster in Training

Greetings!

Recently I've been updating an image resize class I found on the internet. What I needed to have was a script that would crop an image in order to fit in a defined with a fixed width an height. However, after the image is redimensioned, (keeping the aspect ratio), it apears repeated on the slider. Is there any way to solve this? I've been hammering my head over this for the past hours with no results.

EDIT: The croped image on server appears correctly

Here's the code that manipulates the image

## --------------------------------------------------------

			public function resizeImage($newWidth, $newHeight, $option="auto")
			{
				// *** Get optimal width and height - based on $option
				$optionArray = $this->getDimensions($newWidth, $newHeight, $option);

				$optimalWidth  = $optionArray['optimalWidth'];
				$optimalHeight = $optionArray['optimalHeight'];


				// *** Resample - create image canvas of x, y size
				$this->imageResized = imagecreatetruecolor($optimalWidth, $optimalHeight);
				imagecopyresampled($this->imageResized, $this->image, 0, 0, 0, 0, $optimalWidth, $optimalHeight, $this->width, $this->height);


				// *** if option is 'crop', then crop too
				if ($option == 'crop') {
					$this->crop($optimalWidth, $optimalHeight, $newWidth, $newHeight);
				}
				if($option == 'toSize')
				{
					$this->cropToSize($optimalWidth, $optimalHeight, $newWidth, $newHeight);
				}
			}

			## --------------------------------------------------------
			private function getDimensions($newWidth, $newHeight, $option)
			{

			   switch ($option)
				{
					case 'exact':
						$optimalWidth = $newWidth;
						$optimalHeight= $newHeight;
						break;
					case 'toSize':
						$optionArray = $this->getSizeByAuto($newWidth, $newHeight);
						$optimalWidth = $optionArray['optimalWidth'];
						$optimalHeight = $optionArray['optimalHeight'];
						break;
					case 'portrait':
						$optimalWidth = $this->getSizeByFixedHeight($newHeight);
						$optimalHeight= $newHeight;
						break;
					case 'landscape':
						$optimalWidth = $newWidth;
						$optimalHeight= $this->getSizeByFixedWidth($newWidth);
						break;
					case 'auto':
						$optionArray = $this->getSizeByAuto($newWidth, $newHeight);
						$optimalWidth = $optionArray['optimalWidth'];
						$optimalHeight = $optionArray['optimalHeight'];
						break;
					case 'crop':
						$optionArray = $this->getOptimalCrop($newWidth, $newHeight);
						$optimalWidth = $optionArray['optimalWidth'];
						$optimalHeight …
fantasma 0 Junior Poster in Training

Thank you! I'll try and integrate with JAVA! ;)

fantasma 0 Junior Poster in Training

I have those files. something.l and something.y and I need to create an exe in order to, in a JAVA application do something like "cmd executable.exe" < "filetobeparsed" + "parsedfile.xml"

How to make that exe is my question, since I don't have a clue in how to do it

fantasma 0 Junior Poster in Training

Greetings,

I've got a working flex/bison parser that I would like to run from an exe file. However, I can't find the knowledge to achieve that.

Do I need to create a C file, with an exec function to call the files? If so, what files do I call in the exec? Anyone knows how to do something like that?

I really need a hint for this one!

Cheers!

fantasma 0 Junior Poster in Training

My DB is like

ID | tipo_cont | conteudo_cont | id_menu
 1 | something | belongs_to_something | 1
 2 | someone   | belongs_to_someone | 1
 3 | another   | belongs_to_another | 2
 4 | who       | belongs_to_who| 1

//And I want do not want to get all records that have 1 at id_menu. Just, for //example, I want to be able to echo content_cont belonging to something and who and //print it by doing: 

echo $row['who'];
echo $row['something'];

Hope it's understandable ;)

PS: How did you got that adress? :P Are you Tuga? :P

fantasma 0 Junior Poster in Training

It works!

However it keeps creating n arrays while the loop is not finished. Is there anyway to just create one array? Global array probably?

Not that really important though, as it works like a charm, but, I would be thankful for the knowledge ;)

fantasma 0 Junior Poster in Training

Greetings!

I'm trying to solve a little problem that occurs when I try to kinda make an associative array out of an associative array. I wish to associate 2 fields coming from mySQL so I can make a simple associated print for the records I want (and I do not wish to print all the records coming from the DB)

Here's my code:

$sql = "SELECT tipo_cont, conteudo_cont FROM CONTACTOS WHERE id_menu = '1'";
						
$query = mysql_query($sql);
	if(!$query)
	{
		echo "Erro ao executar a query".mysql_error();
	}		
						
						
							
	while($row = mysql_fetch_assoc($query))
	{	
							
		$cont = array($row['tipo_cont'] => $row['conteudo_cont']);
							
		print_r($cont);
	}
						
	echo $cont['Morada'];

So, what I want is field 'tipo_cont' to index the respective DB field in 'conteudo_cont'.

Would be a lot easier if I didn't wanted just some records to be shown.

Glad for all the possible help

Cheers

fantasma 0 Junior Poster in Training

bump! Anyone? I really need this one done! Any kind soul?

fantasma 0 Junior Poster in Training

The "whichDiv" variable is responsible for determining which div need to be poped out, as all of them are populated with database records, so, for each record, and in order to give the show/hide effect uniquely to each record, I need to diferentiate each one and send that unique ID to that variable. If i remove that variable, it will only pop-out the same 1st record for every diferent ID's.

The problem is that, for each gallery (this one in particular is related to a portfolio with several user defined galleries so, i'll call it galleries), I want to list all the images it has, and apply them certain operations (CRUD, etc). So, for each gallery I want to show/hide the associated images with that gallery. The problem, as I said above, is that, when I click the button to trigger those records, for each diferent gallery it only pops the first associated record.

fantasma 0 Junior Poster in Training

No, before hidding the div element, all the records were displaying correctly!

fantasma 0 Junior Poster in Training

Greetings!

I'm having a problem showing a set of records using jQuery. When I click in the designated link, the script only shows the first record that comes from the database. Am I doing something wrong?

Here's the code


jQuery

$(document).ready(function() {
//hides the slickbox as soon as the DOM is ready
  $('div.contentor_imagens').hide();
 //shows the slickbox on clicking the noted link
});
function showEtiq(whichDiv) {
	showThis = "#contentor_imagens" + whichDiv;
	$(document).ready(function() {
	$(showThis).toggle("slow");
 });
}

HTML/PHP

echo'<div class="contentor_upload_galeria" >
				
<div class="img_port_options" id="img_port_options'.$id.'">
<a onclick="showSup('.$id.')"><div class="img_manage_up"></div></a>
<div class="img_manage_mup"></div>
<a onclick="showEtiq('.$id.')"><div class="img_manage_edit"></div></a> //DIV THAT IS CLICKED TO TRIGGER THE FUNCTION
</div>
				
	
				/*

DATABASE QUERY STUFF HERE...

*/		

//BLOCK TO BE SHOWN. IT ONLY SHOWS THE FIRST RECORD COMING FROM DB


echo'<div class="etiquetas_imagens"  id="contentor_imagens'.$id.'">
<div class="titulo_etiq_imagem">'.$row2['descricao'].'</div>
<div class="botoes_comando">
<a href="#"><div class="visualiza" id="visualiza"></div></a>
<a href="view.php?id='.$row2['ID'].'"><div class="edita"></div></a>
<a href="../crud/delete.php?id='.$row2['ID'].'&mod='.$table.'"><div class="elimina" id="delete"></div></a>
</div>
						
<div class="contentor_visualiza" id="contentor_visualiza'.$id.'">
<img src="'.$row2['caminho'].'" title="'.$row2['descricao'].'"></img>
</div>
				
</div>';

Thanks in advance for all the help!

Cheers!

fantasma 0 Junior Poster in Training

You're the Man!!!! :P

Wasn't really working the way you posted because it was lacking the # before "upload", but after that, it's working perfectly!

So the function would rather be

function showLoad(whichDiv) {
showThis = "#upload" + whichDiv;
$(showThis).toggle("slow");
}

Thanks so much for you help!

fantasma 0 Junior Poster in Training

Sorry mate, that was my first try, but, with that script, if I click the link for just one record, it will apear the div for all the records coming from the DB.

Basically, what I want is that, when I click in link "upimagem", it shows up a litlle box having an upload form for that specific record. However with that solution, every time I click the button, all the boxes for each record pop out.

Thanks for your effort SolidSolutions

fantasma 0 Junior Poster in Training

The div is basicaly a styled link, not intended to have content, just a css sprited image

fantasma 0 Junior Poster in Training

Sorry mate, ATM I'm working on Localhost... any questions I might answer?

fantasma 0 Junior Poster in Training

Hi there!

I have this function in jQuery that is suposed to toggle a div, according to each different record I click, in order to toggle an upload form. However I can't seem to get it to work properly.

Anyone could help? I really need this working today :(

jQuery Script

$(document).ready(function() {
 // hides the slickbox as soon as the DOM is ready
  $('div.upload').hide();
 // shows the slickbox on clicking the noted link  


$('div.upimagem').click(function() {    
    $(this).parents().next('div.contentor_upload').toggle("slow"); 
    return false;  
});
});

The records coming from the DB and the DIV that needs toggling

echo'<div class="etiquetas">';

		echo '<div class="tit_etiq">';
		
		
				echo $titulo;


		echo'</div>';
		
		echo'<div class="botoes_comando">
			
			<a href="#"><div class="visualiza" id="visualiza"></div></a>
			<a href="view.php?id='.$id.'"><div class="edita"></div></a>
			<a href="../crud/delete.php?id='.$id.'&mod='.$table.'"><div class="elimina" id="delete"></div></a>

// WHEN YOU CLICK THIS LINK "upimagem" THE DIV TOGGLES
			<a href="#"><div class="upimagem"></div></a>

		</div>';

		echo'</div>
		<div class="contentor_visualiza" id="contentor_visualiza'.$id.'">

		<?php $table = "content_empresa";?>

	<div class="view">
		<form name="edita_records" method="POST" action="../crud/insert.php?mod=<?php echo $table ?>">
			<textarea class="area_titulo_view" name="titulo_emp" readonly="readonly">';
			
			echo $titulo;
			
			echo'</textarea>
			<textarea class="area_visualiza" name="content_emp" readonly="readonly">';
			echo $descricao;
			echo '</textarea>
			
		
	</form>
</div>



</div>


/* THIS IS THE DIV THAT SHOULD BE TOGGLED */

<div class="contentor_upload">
		<div class="upload">
			<form name="upload_imagem" method="post" enctype="multipart/form-data"  action="../upload/upload.php?id_int='.$id.'&mod='.$table.'">
			<input type="file" name="image">
			<input name="submit" type="submit" value="Upload">
			</form>
		</div>
	</div>';
}
echo '</div>';

Glad for all the help possible

fantasma 0 Junior Poster in Training

Solved.

thanks for your sugestions, but I ended up using a "." before each extension in the array though.

fantasma 0 Junior Poster in Training

Hello fellow programmers,

I've built an upload script that, as usual, verifies if a file extension is allowed. However, the comparison seems to not be working, as it gives me an unhauthorized file trying to be uploaded (when in fact the file has an authorized extension).

If i comment the block below, the upload works fine

Anyone could give me a hint?

//Array containing the authorized extensions
$ext_permitidas = array("jpg","jpeg","gif","png"); 

/* SOME CODE HERE */

//String comparison and validation

$ext = substr($filename, strpos($filename,'.'), strlen($filename)-1);

if(!in_array($ext,$ext_permitidas))
    die('A extensão da imagem '.$ext.' não é permitida');
fantasma 0 Junior Poster in Training

Because I needed C++ to insert a row directly in the DB, and before that, update a single field. However I managed to solve this problem with this trigger

CREATE OR REPLACE TRIGGER RESET_ACTIVO BEFORE
  INSERT ON TABELA
  FOR EACH ROW 
  BEGIN
  
  UPDATE TABELA SET TABELA.ACTIVO = 0 WHERETABELA.NOME = :NEW.NOME;
  
  END;

Thanks for your concern anyway ;)

fantasma 0 Junior Poster in Training

Greetings,

I'm having some trouble creating a trigger that, before I insert something in a table, it resets an existing record field to 0.

Example

I have in the table a field named "Name" and another named "Active". Each field has a diferent ID

The last entry of a "Name" should alaways be the active one, but, I must have several entries that can be active, difering in the name and ID.

However, its a bit complex, and I can't think in a solution. Anyone could give me a help to a possible implementation/solution?

Thanks in advance...

fantasma 0 Junior Poster in Training

thank you it works! And thank you for your advice, will implement rigth away.

Added reputation.

Cheers mate ;)

fantasma 0 Junior Poster in Training

Here's the code

<div class="contentor_records">





		<div class="etiquetas"><div class="tit_etiq">			asdasdasdasd

			

			</div><div class="botoes_comando">

			

			<a href="#"><div class="visualiza" id="visualiza"></div></a>

			<a href="view.php?id=24"><div class="edita"></div></a>

			<a href="../crud/delete.php?id=24&mod=content_empresa"><div class="elimina" id="delete"></div></a>

			<a href="../upload/upload_crop.php?id=24&mod=content_empresa"><div class="up_imagem"></div></a>

		</div></div>

		<div class="contentor_visualiza" id="contentor_visualiza24">



		<?php $table = "content_empresa";?>



	<div class="insert">

		<form name="edita_records" method="POST" action="../crud/insert.php?mod=<?php echo $table ?>">

			<textarea class="area_titulo_adic" name="titulo_emp">			asdasdasdasd

			

			</textarea>

			<textarea class="area_visualiza" name="content_emp"><p>asdasdasdasdasdasdas</p>			

			</textarea>

			

		

			<div class="buttons">

				

				<input type="submit" name="inserir" class="positive" value="Guardar">

					<img src="../gfx/guardar.png" alt=""/> 

				</input>

				

			</div>

	</form>

</div>



</div><div class="etiquetas"><div class="tit_etiq">Introdução Empresa

			

</div><div class="botoes_comando">

			

			<a href="#"><div class="visualiza" id="visualiza"></div></a>

			<a href="view.php?id=11"><div class="edita"></div></a>

			<a href="../crud/delete.php?id=11&mod=content_empresa"><div class="elimina" id="delete"></div></a>

			<a href="../upload/upload_crop.php?id=11&mod=content_empresa"><div class="up_imagem"></div></a>

		</div></div>

		<div class="contentor_visualiza" id="contentor_visualiza11">



		<?php $table = "content_empresa";?>



	<div class="insert">

		<form name="edita_records" method="POST" action="../crud/insert.php?mod=<?php echo $table ?>">

			<textarea class="area_titulo_adic" name="titulo_emp">Introdução Empresa

			

</textarea>

			<textarea class="area_visualiza" name="content_emp">Somos uma empresa que se dedica à imagem no sentido lato da palavra, desenvolvendo projectos de design gráfico, interiores, industrial e multimédia.

<br><br>

A função da Artzende é materializar as ideias, apresentar soluções, filosofias de comunicação, espaços funcionais e estéticos, sistemas industriais eficientes, rentáveis e seguros.			

<br><br>

Temos como filosofia <i>"criado pelo homem, para pessoas"</i> e é neste sentido que trabalhamos em todos os nossos projectos.			</textarea>

			

		

			<div class="buttons">

				

				<input type="submit" name="inserir" class="positive" value="Guardar">

					<img src="../gfx/guardar.png" alt=""/> 

				</input>

				

			</div>

	</form>

</div>



</div></div>

</div>
fantasma 0 Junior Poster in Training

Sorry mate, what do you mean by "resulting HTML" ??

fantasma 0 Junior Poster in Training

It seems to have no effect mate sorry

fantasma 0 Junior Poster in Training

I want to show up, in the case of clicking "View" this div "contentor_visualiza"

Unfortunately your solution didn't work. It does not even show any did...

Thanks for your effort anyway

fantasma 0 Junior Poster in Training

I there everyone.

I've been wondering if someone could help to glue up my broken head with this one.

I've got some "labels" which show up, dynamicaly, the data coming from mySql through PHP. In those labels I've got 4 buttons for uploading an image, deleting the respective entry, editing and view the entry with its respective ID.

However, i've trying with jQuery to add some "on the fly" features, in other words, for example, if I click in "view" button, it would only show that specific ID data without going to another page (that would be to easy :D), but by showing an hidden DIV with that content.

But it has some flaws, because, if I click that button, it shows all the divs to all the records which I don't want.

Here's the jQuery code:

$(document).ready(function() {
 // hides the slickbox as soon as the DOM is ready
  $('div.contentor_visualiza').hide();
 // shows the slickbox on clicking the noted link  

 
 // toggles the slickbox on clicking the noted link  
  $('div.visualiza').click(function() {
    $('div.contentor_visualiza').toggle(200);
    return false;
  });
});

AND THE HTML CODE

<div class="contentor_records">


		<?php 

		
		$sentence = "SELECT ID,titulo,descricao,imagem FROM $table ";
		$query = mysql_query($sentence);
		if(!$query)
		{
			echo "Erro ao executar a query".mysql_error();
		}
		while ($row = mysql_fetch_array($query)){
		
		$titulo=$row['titulo'];
		$id=$row['ID'];
		$descricao = $row['descricao'];
		$imagem=$row['imagem'];
		
		echo'<div class="etiquetas">';

		echo '<div class="tit_etiq">';
		
		
				echo $titulo;


		echo'</div>';
		
		echo'<div class="botoes_comando">
			
			<a href="#"><div class="visualiza" id="visualiza"></div></a>
			<a href="view.php?id='.$id.'"><div class="edita"></div></a>
			<a href="../crud/delete.php?id='.$id.'&mod='.$table.'"><div class="elimina" id="delete"></div></a>
			<a href="../upload/upload_crop.php?id='.$id.'&mod='.$table.'"><div class="up_imagem"></div></a>
		</div>';

		echo'</div>
		<div class="contentor_visualiza" id="contentor_visualiza'.$id.'">

		<?php $table …
fantasma 0 Junior Poster in Training

Sorry for the language used in the page (Portuguese) if it confused you up a bit. However I quited using this aproach, and started using a CRUD like aproach, redirecting each click to its respective action. I couldn't loose to much time figuring out what was going wrong with this. Maybe in a few days I'll be updating this to be more visually atractive.

Anyway, although I've tested it with no success, thank you very much for you patience and help! ;)

fantasma 0 Junior Poster in Training

Hi There

I've been hammering my head with this for quite a while, and every solution I've tried didn't work, so I was wandering if you could help me with this.

I've got a small div that is displayed for each record existing in the database, in order that, later, users are able to "apply some CRUD" to the records.

However, the code that I have written (in javascript) to show or hide the div's that display or update the fields (haven't written the one to delete yet), are just displaying the records for one field, either if I click the button to edit another field or not, it just displays the same record.

Is there any way, that, given an unique ID stored in the database, this starts working properly?

Here's the code

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="pt-pt">


<?php include '../includes/bdconn.php'?>


<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<link href="../css/style_back.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../js/jquery-1.4.4.js"></script>
<script type="text/javascript">
  $(document).ready(function() {
  // Hide the "view" div.
  $('div.display').hide();
  // Watch for clicks on the "slide" link.
  $('div.visualiza').click(function() {
  // When clicked, toggle the "view" div.
  $('div.display').slideToggle(400);
  return false;
});
});
$(document).ready(function() {
  // Hide the "view" div.
  $('div.update').hide();
  // Watch for clicks on the "slide" link.
  $('div.edita').click(function() {
  // When clicked, toggle the "view" div.
  $('div.update').slideToggle(400);
  return false;
});
});
</script>


<title>Untitled Document</title>
</head>

<div id="container_back">


<div id="container_menu">
<div class="menu_bar">
	<ul>
	<a href="../backoffice.php" class="home"><li></li></a>
	<a href="back_empresa.php" class="company"><li></li></a> …
fantasma 0 Junior Poster in Training

Yes, that's what I did and it works. Not as I expected, but, nevertheless, it works...

fantasma 0 Junior Poster in Training

Yes, below the image I can do it, however, the caption div will be positioned to the right of the image, which I can't because, block would be swept with the image to the left... Ugly :S

I uploaded an example, if you would like to see. You must pass the first image...

fantasma 0 Junior Poster in Training

Anyone? I really could use a hint! Please... :(

fantasma 0 Junior Poster in Training

Thank you so much. It doesn't displays 100% perfect in ie7, but it surely does the job by 99,9%.

However, at the moment I don't have any means to test it on firefox 3.5 (my installed version is 3.6) but, I will in a few minutes be available to give some feedback on that too.

Thank you... Icreased your rank ;)

fantasma 0 Junior Poster in Training

Can anyone help me please? I really really need this working

fantasma 0 Junior Poster in Training

Thank you for your reply, but, unfortunately, no luck. didn't altered a thing :(

fantasma 0 Junior Poster in Training

Greetings

I have this page, which will have a slider gallery based on the EasySlider plugin

http://fantasma98.byethost12.com/restaurante/galeria.php

The problem I'm having is that, I don't know how to display a title and a description of the given image (been trying for hours to move positioned divs to display it).

I would like, if possible, some advice on how to display a title and a description below the div "Galeria" and, when the first image slides, its correspondent content also slides and then displaying the title and description for the 2nd image.

The javascript for easyslider is

/*
 * 	Easy Slider 1.7 - jQuery plugin
 *	written by Alen Grakalic	
 *	http://cssglobe.com/post/4004/easy-slider-15-the-easiest-jquery-plugin-for-sliding
 *
 *	Copyright (c) 2009 Alen Grakalic (http://cssglobe.com)
 *	Dual licensed under the MIT (MIT-LICENSE.txt)
 *	and GPL (GPL-LICENSE.txt) licenses.
 *
 *	Built for jQuery library
 *	http://jquery.com
 *
 */
 
/*
 *	markup example for $("#slider").easySlider();
 *	
 * 	<div id="slider">
 *		<ul>
 *			<li><img src="images/01.jpg" alt="" /></li>
 *			<li><img src="images/02.jpg" alt="" /></li>
 *			<li><img src="images/03.jpg" alt="" /></li>
 *			<li><img src="images/04.jpg" alt="" /></li>
 *			<li><img src="images/05.jpg" alt="" /></li>
 *		</ul>
 *	</div>
 *
 */

(function($) {

	$.fn.easySlider_gal = function(options){
	  
		// default configuration properties
		var defaults = {			
			prevId: 		'sld_bt_esq',
			prevText: 		'',
			nextId: 		'sld_bt_dir',		
			nextText: 		'',
			controlsShow:	true,
			controlsBefore:	'',
			controlsAfter:	'',	
			controlsFade:	true,
			firstId: 		'firstBtn',
			firstText: 		'First',
			firstShow:		false,
			lastId: 		'lastBtn',	
			lastText: 		'Last',
			lastShow:		false,				
			vertical:		false,
			speed: 			800,
			auto:			false,
			pause:			2000,
			continuous:		false, 
			numeric: …
fantasma 0 Junior Poster in Training

Greetings once again

I have this form created in my page, and I pretend it to be fully tableless however, margins in IE7 aren't equal to the ones in other browsers. Also, adding another problem to the party, Firefox 3.5 (the only one different from 3.6, which renders correctly, that i've tested the page on) cuts the font in the input fields, being able to see just half of it.

You can see the page in the following link:

http://fantasma98.byethost12.com/restaurante/encomendas.php

here's the CSS for the form

form
{
	margin:0;
	padding:0;
}
.form_enc
{
	width:375px;
	height:365px;
	float:left;
	border: 20px solid #FFFFFF;
}
.form_enc input, .form_enc textarea
{
	font-family:'aller_i';
	font-size:13px;
	overflow:hidden;
	resize: none;
	
	
}
.form_enc_nome input,.form_enc_ent input
{

	box-sizing: content-box; -webkit-box-sizing: content-box; -moz-box-sizing: content-box;
	width:362px;
	height:10px;
	border:none;
	background-color:#e0e2e1;
	margin:1px;
	font-family:'aller_bi';
	font-size:13px;
	overflow:hidden;
	color:#48554c;
	
	
	
}
.form_enc_loc input,.form_enc_email input, .form_enc_data input, .form_enc_telf input
{
	
box-sizing: content-box; -webkit-box-sizing: content-box; -moz-box-sizing: content-box;
	width:175px;
	
	height:10px;
	
	float:left;
	background-color:#e0e2e1;
	border:none;
	margin:1px;
	
	font-family:'aller_bi';
	font-size:13px;
	
	overflow:hidden;
	color:#48554c;
	
}
.form_enc_coments textarea
{
	box-sizing: content-box; -webkit-box-sizing: content-box; -moz-box-sizing: content-box;
	
	width:362px;
	height:250px;
	border:1px solid #FFFFFF;
	
	background-color:#e0e2e1;
	
	font-family:'aller_bi';
	color:#48554c;
	font-size:13px;
	overflow:hidden;
	resize:none;
	
}
fantasma 0 Junior Poster in Training

Solved... Just by putting footer container inside the div container of the pages

fantasma 0 Junior Poster in Training

No luck mate. The footer hides the content div, and if add padding or margins, it just limits to come down in front of the content div, and, helps to mess up with other browser's perfect view....

fantasma 0 Junior Poster in Training

Greetings,

I've been pulling of all of my hair with this old piece of junk called IExplorer 7 because, my footer is over the content div. I've tried Sticky hack and it didn't solve anything so, you're pretty much my last hope of getting this done. In all other major browsers, including IE 8, all looks fine

The page can be viewed here:

http://fantasma98.byethost12.com/restaurante/carne.php

My css (i'll post only the one that looks relevant to me):

/*###################################################################################
#####################################################################################
####  PAGE CONTAINER / OTHERS
#####################################################################################
###################################################################################*/

body
{
	background-color:#5a6f5d;	
	margin:0;
	padding:0;
}
#container
{
	width: 100%; 
    margin: 0px auto;
    text-align: center;
	background-color:#5a6f5d;	
	
}
#container_top
{
	
    margin: 0px auto;
    text-align: center;
	
	background-color:#FFFFFF;	
	
	
}


/*###################################################################################
#####################################################################################
####  FOOTER
#####################################################################################
###################################################################################*/



#footer_container
{
	
	width: 840px; 
    margin: 0px auto;
    text-align: left;
	padding:0;
	background-color:#5a6f5d;		
	
}
.esp_rdp
{
	
	width:840px;
	
	height:20px;
	float:left;
}

.rodape {
	
	
	margin-top:15px;
	padding:0;
	
	background-color:#5a6f5d;
	
	width: 100%;
	height:50px;
	border:none;
	
	}
.logo_signed{
	
	width:200px;
	height:13px;
	float:left;
	font-size:11px;
	text-align:left;
	
}
.copyright{
	
	padding-top:10px;
	width:240px;
	line-height:13px;
	float:left;
	font-size:8px;
	text-align:left;
	font-family:'aller_b';
	color:#bdbebd;
	text-decoration:none;
	\left:0px;
	
}
/* ----------------------------------------------------- */
.div_espaco_rod{

	width:420px;
	height:105px;
	float:left;
	
	font-size:11px;
	text-align:left;
	
}
.rp_separador{
	width:10px;
	height:90px;
	float:left;
	font-size:0px;
}


/* ----------------------------------------------------- */

.copywrite{
	
	padding-top:10px;
	width:240px;
	line-height:13px;
	float:left;
	
	font-size:8px;
	text-align:left;
	font-family:'aller_b';
	color:#FFFFFF;
	text-decoration:none;
	\left:0px;
	
}

.rp_coluna3{
	width:120px;
	height:105px;
	float:left;
	font-size:11px;
	text-align:left;
	right:20%;
	
}
.partilha_texto{
	width:120px;
	height:13px;
	font-size:11px;
	text-align:left;
	font-family:'aller_b';
	color:#FFFFFF;
	text-decoration:none;
}
.partilha_bloco{
	width:120px;
	height:20px;
	text-align:left;
}
.menu_idioma
{
	margin-top:10px;
	height:105px;
	float:right;
	
}
.menu_idioma_lang
{
	float:left;
	

}
.separador{
	float:left;
	margin-top:-10px;
	width:10px;
	height:20px;
	background:url(../gfx/menu_separador.png) center top no-repeat;
}
a.link_footer_active
{
	font-size:9px;
	line-height:10px;
	font-family:'aller';
	color:#FFFFFF; …
fantasma 0 Junior Poster in Training

So let me try to be a little more specific. Printing to the terminal is just a mean to an end.

I Want to be able to read 2 files I've created and then, put them in a linked list.

The thing is, the values that are beeing outputed by the read are wrong.

I have 2 files like this

(They're a bit diferent from the first post, so I have worked on them a little bit)

Loja.txt:
2002,Loja 1,Quantidade Encomendada:20
2003,Loja 2,Quantidade Encomendada:30

Armazemns.txt
100002,Armazem 1,24-BC-23,8500,24-EV-51,10000
100003,Armazem 2,24-EV-51,10000

I want to be able to read them and then put them in the following List

#pragma once


#include "No.h"

using namespace std;


template<class T>
class Lista {
private:

    No<T> *cabeca;

    void destroilista();

public:
    Lista();
    Lista(const Lista<T>& l);
    ~Lista();
    bool vazia() const;
    void insere(int k, const T & elem);
    void remove(int k, T &x);
    void encontra(int k, T &x) const;
    int comprimento() const;

    const Lista<T> & operator =(const Lista<T> & l);

    void escreve(ostream& out) const;

};

template <class T>
Lista<T>::Lista() {
    cabeca = NULL;
}

template <class T>
Lista<T>::Lista(const Lista<T>& l) {
    No<T> * apno = new No<T>;

    if (l.cabeca)
        cabeca = apno;
    else
        cabeca = NULL;

    No<T> * apaux = l.cabeca;

    while (apaux) {
        apno->info = apaux->info;
        if (apaux->prox == NULL) {
            apno->prox = NULL;
            apaux = apaux->prox;
        } else {
            apno->prox = new No<T>;
            apno = apno->prox;
            apaux = apaux->prox;
        }
    }
}

template <class T>
Lista<T>::~Lista() …