Please help, accelerometer problem

Hello! I have to make this simple project but I have a big problem: the accelerometer in the picture (5 pins, power supply plus the 3 axes) is impossible to find, so I have bought a very common ADXL345 like this one.

Now, my problem is that I don’t know how to connect it with the Arduino Uno board. Which accelerometer pins should go to the A0, A2 and A4 arduino pins? Or how do I need to modify the code below in order to use the ADXL345 accelerometer? It should be a minimal change in the code, one that a noob kid is supposed to be able to make.
THANK YOU!

void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
pinMode(A0, INPUT);
pinMode(A2, INPUT);
pinMode(A4, INPUT);
pinMode(12, OUTPUT);
}

void loop() {
// put your main code here, to run repeatedly:
int x = analogRead(A0);
int y = analogRead(A2);
int z = analogRead(A4);

Serial.print("x = ");
Serial.println(x);
/Serial.print("y = ");
Serial.println(y);
Serial.println("z = ");
Serial.println(z);
/
delay(1000);

if( x>400)
{
digitalWrite(12,HIGH);
}
else
{
digitalWrite(12,LOW);
}
}

I have a big problem: the accelerometer in the picture (5 pins, power supply plus the 3 axes) is impossible to find

The ADXL337 is a chip with 3 analog outputs as the instructable seems to use.

Now, my problem is that I don’t know how to connect it with the Arduino Uno board. Which accelerometer pins should go to the A0, A2 and A4 arduino pins? Or how do I need to modify the code below in order to use the ADXL345 accelerometer?

The ADXL345 is an accelerometer with digital output, so it cannot be used with the posted code.

Thank you very much, now I see. Then could somebody please help me with a few code lines to be added to the code below? I have tested it and it works fine, I just need to trigger the pin 12 (a buzzer) when the ADXL345 records vibrations.
Thank you!

#include <Wire.h>  
#define Register_ID 0
#define Register_2D 0x2D
#define Register_X0 0x32
#define Register_X1 0x33
#define Register_Y0 0x34
#define Register_Y1 0x35
#define Register_Z0 0x36
#define Register_Z1 0x37
int ADXAddress = 0x53;  //I2C address
int reading = 0;
int val = 0;
int X0,X1,X_out;
int Y0,Y1,Y_out;
int Z1,Z0,Z_out;
double Xg,Yg,Zg;

void setup()
{
Serial.begin(9600);
delay(100);
Wire.begin(); 
delay(100);
Wire.beginTransmission(ADXAddress);
Wire.write(Register_2D);
Wire.write(8);
Wire.endTransmission();
Serial.println("Accelerometer Test ");
} 
void loop()
{
Wire.beginTransmission(ADXAddress);
Wire.write(Register_X0);
Wire.write(Register_X1);
Wire.endTransmission();
Wire.requestFrom(ADXAddress,2);
if(Wire.available()<=2);
{
  X0 = Wire.read();
  X1 = Wire.read();
  X1 = X1<<8;
  X_out = X0+X1;
} 
Wire.beginTransmission(ADXAddress);
Wire.write(Register_Y0);
Wire.write(Register_Y1);
Wire.endTransmission();
Wire.requestFrom(ADXAddress,2);
if(Wire.available()<=2);
{
  Y0 = Wire.read();
  Y1 = Wire.read();
  Y1 = Y1<<8;
  Y_out = Y0+Y1;
} 
Wire.beginTransmission(ADXAddress);
Wire.write(Register_Z0);
Wire.write(Register_Z1);
Wire.endTransmission();
Wire.requestFrom(ADXAddress,2);
if(Wire.available()<=2);
{
  Z0 = Wire.read();
  Z1 = Wire.read();
  Z1 = Z1<<8;
  Z_out = Z0+Z1;
} 
Xg = X_out/256.00;
Yg = Y_out/256.00;
Zg = Z_out/256.00;
Serial.print("X=");
Serial.print(Xg);
Serial.print("\tY=");
Serial.print(Yg);
Serial.print("\tZ=");
Serial.println(Zg);
delay(300);  
}

http://wiki.sunfounder.cc/index.php?title=Digital_Accelerometer_ADXL345_Module

Please edit your posts to add code tags, as described in the "How to use this forum" post.