Array block along a 3D curve without rotation on Z axis only

I’m using “arraycrv” command and with road-like and freeform options but no luck, I’m actually trying to array a street lamp block along a mountain road, the issue is that when there is a bend in the road (curve) the block will sit perpendicular to it! if I choose the no-rotation option, it works, but it won’t follw the road correctly in X and Y axis, but in Z axis, it’s always perpendicular to c-plan wich it is what i want.
is there a script to array a block along a 3D curve without rotation on Z axis only?
thanks.