Need help with a trigger problem?

I need help with the following code it will not allow me to run it i am trying to make it so that when the game object collides with the trigger it will push the game object ahead a certain amount of meters.

using UnityEngine;
using System.Collections;

public class pushcharacter : MonoBehaviour {
    private Vector3 speed = new Vector3(3, 0, 0);
    void FixedUpdate() {
        rigidbody.MovePosition(rigidbody.position + speed * Time.deltaTime);
    }
}
public class Transform explosion;
public class Transform trnsfrm;
	
	void OnTriggerEnter (Collider obj)
	{
		Instantiate (explosion, trnsfrm.position, Quaternion.identity);
	}

When you say it won’t let you run it, you mean it won’t compile? Normally, telling us the errors you’re seeing more specifically can help pinpoint the problem.

In this case, I think your problem is the declaration of your public variables explosion and trnsfrm, they shouldn’t have class before them - i.e,

public Transform explosion;
public Transform trnsfrm;

Does that solve the problem for you?